explosion / srsly

🦉 Modern high-performance serialization utilities for Python (JSON, MessagePack, Pickle)
MIT License
438 stars 31 forks source link

Wordwises works, X-Ray doesn't #58

Closed benninkcorien closed 3 years ago

benninkcorien commented 3 years ago

Wordwise seems to run fine, X-Ray errors :

Traceback (most recent call last):
File "calibre\gui2\threaded_jobs.py", line 83, in start_work
File "calibre_plugins.worddumb.parse_job", line 37, in do_job
File "C:\Users\USERNAME\AppData\Roaming\calibre\plugins\worddumb-libs\spacy_3.1.1_3.8\spacy\__init__.py", line 11, in <module>
File "C:\Users\USERNAME\AppData\Roaming\calibre\plugins\worddumb-libs\thinc_8.0.8_3.8\thinc\__init__.py", line 5, in <module>
File "C:\Users\USERNAME\AppData\Roaming\calibre\plugins\worddumb-libs\thinc_8.0.8_3.8\thinc\config.py", line 14, in <module>
File "C:\Users\USERNAME\AppData\Roaming\calibre\plugins\worddumb-libs\srsly_2.4.1_3.8\srsly\__init__.py", line 1, in <module>
File "C:\Users\USERNAME\AppData\Roaming\calibre\plugins\worddumb-libs\srsly_2.4.1_3.8\srsly\_json_api.py", line 6, in <module>
File "C:\Users\USERNAME\AppData\Roaming\calibre\plugins\worddumb-libs\srsly_2.4.1_3.8\srsly\ujson\__init__.py", line 1, in <module>
ModuleNotFoundError: No module named 'srsly.ujson.ujson'

pip says srsly is installed correctly, and C:\Users\USERNAME\AppData\Roaming\calibre\plugins\worddumb-libs\srsly_2.4.1_3.8\srsly\ujson exists and has ujson.c inside among other files..

(unrelated? : I had to manually add blis_0.7.4_3.8 to the worddumb-libs on Windows 10 to clear an other error)

C:\Users\USERNAME\AppData\Roaming\calibre\plugins\worddumb-libs\srsly_2.4.1_3.8\srsly\ujson__init__.py line 1 is :

from .ujson import decode, encode, dump, dumps, load, loads # noqa: F401

Called with args: ((1587, 'MOBI', 'BBGL0Z779A', 'book.mobi', <calibre.ebooks.metadata.book.base.Metadata object at 0x082C44C0>, {'spacy': 'en_coreweb', 'wiki': 'en'}), False, True) {'notifications': <queue.Queue object at 0x082C46B8>, 'abort': <threading.Event object at 0x082C45F8>, 'log': <calibre.utils.logging.GUILog object at 0x082C45C8>}

Windows 10 Python 3.9 Calibre - 5.24

Installed the plugin today.

polm commented 3 years ago

I think you are having trouble with Calibre? We aren't the Calibre developers. It's not clear you have a srsly bug here, it's possible the Calibre folks are doing something wrong. I don't know what you mean by "the plugin", and I've never heard of Wordwise or X-Ray before.

You might want to contact the Calibre developers (or developers of "the plugin") for help with this, I'm not sure what's going on.

From what I can tell about your error, it seems that something may have gone wrong with your srsly install. https://github.com/explosion/spaCy/issues/3750 looks potentially related. You can't use the ujson.c file directly, I think maybe you should have a DLL or something there.

benninkcorien commented 3 years ago

Apologies, I thought I posted this on the WordDumb github repo, https://github.com/xxyzz/WordDumb/issues but must have clicked the wrong tab.

(The Calibre plugin Worddumb is throwing an error related to srsly, I reinstalled it manually with pip -t but that didn't fix it. I mentioned the .c file because I thought it somehow might be pointing to that in the error message about

ModuleNotFoundError: No module named 'srsly.ujson.ujson'  

because there is only one 'ujson' subfolder in the srsly folder, so it should be srsly.ujson ?)

Will post to the correct repo/issues.