post request form now conforms
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
503ffe7f9a
commit
7abec4e257
@ -1,5 +1,6 @@
|
||||
#!/usr/bin/env python3
|
||||
import logging
|
||||
import json
|
||||
from xeger import Xeger
|
||||
from flask_restful import Resource
|
||||
from flask import request
|
||||
@ -69,11 +70,12 @@ class SampleResource(Resource):
|
||||
requests.post(
|
||||
f"http://{STORAGE_HOSTNAME}/object",
|
||||
files={
|
||||
'tag': (None, generated_tag),
|
||||
'file': (
|
||||
'description': (None, json.dumps({'tag': generated_tag}), 'application/json'),
|
||||
'soundfile': (
|
||||
'wave.wav',
|
||||
soundfile,
|
||||
soundfile.content_type)})
|
||||
soundfile.content_type,
|
||||
{'Content-Length': len(soundfile)})})
|
||||
rabbitmq_channel.basic_publish(
|
||||
exchange=RABBITMQ_EXCHANGE,
|
||||
routing_key='feature',
|
||||
|
Loading…
Reference in New Issue
Block a user