-
Notifications
You must be signed in to change notification settings - Fork 725
Open
Description
Environment Information:
- OS: Ubuntu 18.04.6 LTS
- Python Version: 3.6.9
- Quart Version: 0.6.15
- Quart-CORS Version: 0.1.3
Current Situation:
The versions are unspecific, leading to issues with Quart and Quart-CORS APIs when used. For instance:
Traceback (most recent call last):
File "main.py", line 12, in <module>
@app.post("/todos/<string:username>")
AttributeError: 'Quart' object has no attribute 'post'Changing all @app HTTP method calls to this style:
@app.route("/todos/<string:username>", methods=["POST"])
allows successful execution of main.py.
However, it's unable to load the sample project "TODO Plugin (no auth)" at https://chat.openai.com/ and the following error is displayed:
[2023-05-17 15:08:42,918] ERROR in app: Exception on request GET /logo.png
Traceback (most recent call last):
File "/usr/local/lib/python3.6/dist-packages/quart/app.py", line 1451, in handle_request
return await self.full_dispatch_request(request_context)
File "/usr/local/lib/python3.6/dist-packages/quart/app.py", line 1473, in full_dispatch_request
result = await self.handle_user_exception(error)
File "/usr/local/lib/python3.6/dist-packages/quart/app.py", line 892, in handle_user_exception
raise error
File "/usr/local/lib/python3.6/dist-packages/quart/app.py", line 1471, in full_dispatch_request
result = await self.dispatch_request(request_context)
File "/usr/local/lib/python3.6/dist-packages/quart/app.py", line 1519, in dispatch_request
return await handler(**request_.view_args)
File "main.py", line 36, in plugin_logo
return await quart.send_file(filename, mimetype='image/png')
TypeError: send_file() got an unexpected keyword argument 'mimetype'This issue seems to be related to the versioning of Quart and Quart-CORS. Can we specify the versions in the requirements to prevent these issues?
tommy-qichang, evanroyrees and DjangoPeng
Metadata
Metadata
Assignees
Labels
No labels