Getting KeyError '' when launching prodigy

I started playing around with prodigy, following the installation guide.

But on launch I get this error:

> prodigy
Traceback (most recent call last):
  File "/usr/local/opt/python@3.8/Frameworks/Python.framework/Versions/3.8/lib/python3.8/", line 185, in _run_module_as_main
    mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
  File "/usr/local/opt/python@3.8/Frameworks/Python.framework/Versions/3.8/lib/python3.8/", line 144, in _get_module_details
    return _get_module_details(pkg_main_name, error)
  File "/usr/local/opt/python@3.8/Frameworks/Python.framework/Versions/3.8/lib/python3.8/", line 111, in _get_module_details
  File "/Users/leifg/projects/side_projects/leifslist/machine_learning/lib/python3.8/site-packages/prodigy/", line 7, in <module>
    from . import recipes
  File "/Users/leifg/projects/side_projects/leifslist/machine_learning/lib/python3.8/site-packages/prodigy/recipes/", line 4, in <module>
    from ..deprecated import recipes  # noqa
  File "/Users/leifg/projects/side_projects/leifslist/machine_learning/lib/python3.8/site-packages/prodigy/deprecated/", line 10, in <module>
    from ..components.loaders import get_stream
  File "cython_src/prodigy/components/loaders.pyx", line 10, in init prodigy.components.loaders
  File "/Users/leifg/projects/side_projects/leifslist/machine_learning/lib/python3.8/site-packages/prodigy/", line 41, in <module>
    del _uvicorn_log_config["loggers"][""]
KeyError: ''

I'm using an virtualenv with pyton 3.8.4 on macOS with prodigy 1.10.1.

I tried running the first example in the docs

prodigy ner.manual nr_news_headlines blank:en ./news_headlines.jsonl --label PERSON,ORG,PRODUCT,LOCATION` 

which yields the same result.

Hi! It seems like a new version of uvicorn (the library that Prodigy uses for to serve the app) introduced a backwards-incompatible change. We'll release a new Prodigy version with the required change soon, but in the meantime, downgrading uvicorn should fix it:


Thank you!

That helped.

1 Like

Just released v1.10.2 of Prodigy, which upgrades to the latest uvicorn!