-
Notifications
You must be signed in to change notification settings - Fork 122
Closed
Labels
Description
The --debug
flag is not working for us since in Flask it relies on watchdog>=3.0.0 (it uses a symbol that was added in version 3) but functions-framework depends on watchdog (>=1.0.0,<2.0.0) and the automatic resolver doesn't fix it since Flask does not declare an explicit dependancy on watchdog
poetry run functions-framework --target=test --port=8000 --debug
* Serving Flask app 'test'
* Debug mode: on
WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead.
* Running on all addresses (0.0.0.0)
* Running on http://127.0.0.1:8000
* Running on http://10.255.0.229:8000
Press CTRL+C to quit
Traceback (most recent call last):
File "./.venv/bin/functions-framework", line 8, in <module>
sys.exit(_cli())
File "./.venv/lib/python3.9/site-packages/click/core.py", line 1130, in __call__
return self.main(*args, **kwargs)
File "./.venv/lib/python3.9/site-packages/click/core.py", line 1055, in main
rv = self.invoke(ctx)
File "./.venv/lib/python3.9/site-packages/click/core.py", line 1404, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "./.venv/lib/python3.9/site-packages/click/core.py", line 760, in invoke
return __callback(*args, **kwargs)
File "./.venv/lib/python3.9/site-packages/functions_framework/_cli.py", line 43, in _cli
create_server(app, debug).run(host, port)
File "./.venv/lib/python3.9/site-packages/functions_framework/_http/__init__.py", line 38, in run
http_server.run()
File "./.venv/lib/python3.9/site-packages/functions_framework/_http/flask.py", line 25, in run
self.app.run(self.host, self.port, debug=self.debug, **self.options)
File "./.venv/lib/python3.9/site-packages/flask/app.py", line 889, in run
run_simple(t.cast(str, host), port, self, **options)
File "./.venv/lib/python3.9/site-packages/werkzeug/serving.py", line 1097, in run_simple
run_with_reloader(
File "./.venv/lib/python3.9/site-packages/werkzeug/_reloader.py", line 440, in run_with_reloader
reloader = reloader_loops[reloader_type](
File "./.venv/lib/python3.9/site-packages/werkzeug/_reloader.py", line 315, in __init__
from watchdog.events import EVENT_TYPE_OPENED
ImportError: cannot import name 'EVENT_TYPE_OPENED' from 'watchdog.events' (./.venv/lib/python3.9/site-packages/watchdog/events.py)
poetry run pip show Flask watchdog functions-framework
Name: Flask
Version: 2.3.1
Summary: A simple framework for building complex web applications.
Home-page:
Author:
Author-email: Armin Ronacher <armin.ronacher@active-4.com>
License: BSD-3-Clause
Location: /Users/spemberton/code/src/microservices/referral_email_to_seeker/.venv/lib/python3.9/site-packages
Requires: blinker, click, importlib-metadata, itsdangerous, Jinja2, Werkzeug
Required-by: [INTERNAL PACKAGE], functions-framework
---
Name: watchdog
Version: 1.0.2
Summary: Filesystem events monitoring
Home-page: http://github.com/gorakhargosh/watchdog
Author: Yesudeep Mangalapilly
Author-email: yesudeep@gmail.com
License: Apache License 2.0
Location: /Users/spemberton/code/src/microservices/referral_email_to_seeker/.venv/lib/python3.9/site-packages
Requires:
Required-by: functions-framework
---
Name: functions-framework
Version: 3.0.0
Summary: An open source FaaS (Function as a service) framework for writing portable Python functions -- brought to you by the Google Cloud Functions team.
Home-page: https://github.com/googlecloudplatform/functions-framework-python
Author: Google LLC
Author-email: googleapis-packages@google.com
License: UNKNOWN
Location: /Users/spemberton/code/src/microservices/referral_email_to_seeker/.venv/lib/python3.9/site-packages
Requires: click, cloudevents, flask, gunicorn, watchdog
Required-by: