prodigy command fails when linking to a recipe from another user.

This is hard to describe, but I ran a prodigy command that linked to a recipe from another user in my system (Ubuntu 14.04). I use a virtualenv from mkvirtualenv prodigy.

pwd  # /home/me/prodigy

PRODIGY_HOME='/home/me/.prodigy' prodigy command [options] -F /home/someoneelse/prodigy/recipes/custom_recipe.py

From /home/me/prodigy I get one error:

(prodigy) ~/prodigy$ prodigy
Traceback (most recent call last):
  File "/usr/lib/python3.6/runpy.py", line 183, in _run_module_as_main
    mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
  File "/usr/lib/python3.6/runpy.py", line 142, in _get_module_details
    return _get_module_details(pkg_main_name, error)
  File "/usr/lib/python3.6/runpy.py", line 109, in _get_module_details
    __import__(pkg_name)
  File "/home/writelab/envs/prodigy/lib/python3.6/site-packages/prodigy/__init__.py", line 4, in <module>
    from . import recipes, about  # noqa
  File "/home/writelab/envs/prodigy/lib/python3.6/site-packages/prodigy/recipes/__init__.py", line 4, in <module>
    from . import ner, textcat, compare, terms, generic # noqa
  File "/home/writelab/envs/prodigy/lib/python3.6/site-packages/prodigy/recipes/ner.py", line 33, in <module>
    DB = connect()
  File "cython_src/prodigy/components/db.pyx", line 20, in prodigy.components.db.connect
  File "cython_src/prodigy/util.pyx", line 43, in prodigy.util.get_config
  File "cython_src/prodigy/util.pyx", line 242, in prodigy.util.read_json
  File "cython_src/prodigy/util.pyx", line 243, in prodigy.util.read_json
ValueError: Unexpected character in found when decoding object value

From anywhere else:

(prodigy) ~/prodigy/pkg$ prodigy
Traceback (most recent call last):
  File "/usr/lib/python3.6/runpy.py", line 183, in _run_module_as_main
    mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
  File "/usr/lib/python3.6/runpy.py", line 142, in _get_module_details
    return _get_module_details(pkg_main_name, error)
  File "/usr/lib/python3.6/runpy.py", line 109, in _get_module_details
    __import__(pkg_name)
  File "/home/writelab/envs/prodigy/lib/python3.6/site-packages/prodigy/__init__.py", line 4, in <module>
    from . import recipes, about  # noqa
  File "/home/writelab/envs/prodigy/lib/python3.6/site-packages/prodigy/recipes/__init__.py", line 4, in <module>
    from . import ner, textcat, compare, terms, generic # noqa
  File "/home/writelab/envs/prodigy/lib/python3.6/site-packages/prodigy/recipes/textcat.py", line 9, in <module>
    from spacy.pipeline import SentenceSegmenter
  File "pipeline.pyx", line 1, in init spacy.pipeline
  File "arc_eager.pxd", line 12, in init spacy.syntax.parser
  File "search.pxd", line 72, in init spacy.syntax.arc_eager
ValueError: thinc.extra.search.MaxViolation has the wrong size, try recompiling. Expected 104, got 128

None of the prodigy commands work anymore, and I’ve tried python 3.5, 3.6, spacy-nightly alpha 13, 12, and I’ve tried deleting the virtualenvs to no avail :sweat:. I’m thinking it’s a path or Linking issue in Cython?

Looks like the second error was a thinc issue. Downgrading to version 6.8.1 worked.

Also, I can't seem to recreate the first error, so all good now :smile: .

Thanks. I’m confused about this problem because reinstalling with --no-cache-dir has worked for me. I guess just use 6.8.1, and the next release of spacy-nightly will sort it out.

Will be fixed in the upcoming Prodigy v0.3.0! :tada:

1 Like