Moto server hangs with the latest version of werkzeug (v2.2.1)
See original GitHub issueHere is what I do:
mamba env create -n test-moto # this creates a clean environment.
conda activate test-moto
pip install moto # OR mamba install moto -c conda-forge
moto_server -p 5555
then in a different terminal I run
curl "http://localhost:5555/"
Expected behavior:
The curl
should immediately return a result.
Actual behavior:
The moto_server
hangs. The process is at 100% CPU usage so maybe it is busy waiting for something (just a guess).
If werkzeug
is manually downgraded to v2.1.0 (pip install Werkzeug=2.1.0
) or previous everything works as expected.
Here is my complete pip freeze
:
-- edit by @bblommers - removed to clean the thread a bit
Issue Analytics
- State:
- Created a year ago
- Reactions:1
- Comments:24 (4 by maintainers)
Top Results From Across the Web
Changes — Werkzeug Documentation (2.2.x)
Version 2.1.2¶. Released 2022-04-28. The development server does not set Transfer-Encoding: chunked for 1xx, 204, 304, and HEAD responses.
Read more >Release Notes — Airflow Documentation
ExternalTaskSensor no longer hangs indefinitely when failed_states is set, an execute_date_fn is used, and some but not all of the dependent tasks fail....
Read more >Untitled
Swtor imperial agent light side, Kisah merentas masa, Fresh new face permanent ... Argentina eliminatorias 2014 tabla, Eigenen wow server erstellen 2.4.3?
Read more >Wjp - River Thames Conditions - Environment Agency - GOV.UK
New features 4.1.2, John wetenhall carnegie, Orion metallica key, Probation and parole bowling green ky, Aut'chose blogspot. Amc 20 mercado showtimes.
Read more >LSST stack installation problem - Support
Name Version Build Channel _ipyw_jlab_nb_ext_conf 0.1.0 py37_0 ... jbig 2.1 hdba287a_0 jdcal 1.4.1 py_0 jedi 0.14.1 py37_0 jeepney 0.4.2 ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
The breakage of werkzeug was a combination of things - werkzeug introduced some bugs, and also exposed some bugs in Moto. The upcoming
werkzeug==2.2.2
release should at least stop Moto from hanging, but will still throw 404’s for some calls to Moto.For now, Moto has pinned the werkzeug-dependency to < 2.2.x until we have time to resolve this completely.
As a debugging note: Some of Moto’s issues can be solved by setting the attribute
RegexConverter.part_isolating = False
. This will also cause other services to fail, as we only want this attribute for specific services - so we need to find a way to make this service-specific.There’s no date planned @jakirkham, but somewhere this week. I’d like to wait until we get some positive feedback that the dev-version works as expected… (hint, hint) 🙂