xxyzz / WordDumb

A calibre plugin that generates Kindle Word Wise and X-Ray files for KFX, AZW3, MOBI and EPUB eBook.
https://xxyzz.github.io/WordDumb/
GNU General Public License v3.0
349 stars 17 forks source link

can not generate word wise #235

Open JonaTang1984 opened 3 days ago

JonaTang1984 commented 3 days ago

Checkboxes

Describe the bug and copy the error message

calibre, version 7.12.0 (darwin, embedded-python: True) Tonnerre de Brest!: An error occurred, please copy error message then report bug at GitHub.

Starting job: Generating Word Wise and X-Ray for The Most Beautiful Woman in Town Job: "Generating Word Wise and X-Ray for The Most Beautiful Woman in Town" failed with error: Traceback (most recent call last): File "calibre/gui2/threaded_jobs.py", line 85, in start_work File "calibre_plugins.worddumb.parse_job", line 211, in do_job run_subprocess(args, input_str) File "calibre_plugins.worddumb.utils", line 53, in run_subprocess return subprocess.run( ^^^^^^^^^^^^^^^ File "subprocess.py", line 571, in run subprocess.CalledProcessError: Command '['/opt/homebrew/bin/python3', '/Users/jonathantang/Library/Preferences/calibre/plugins/WordDumb.zip', '{"book_id": 9, "book_path": "/Users/jonathantang/Calibre Library/Charles Bukowski/The Most Beautiful Woman in Town (9)/The Most Beautiful Woman in Town - Charles Bukowski.azw3", "mi": null, "book_fmt": "AZW3", "book_lang": "en", "useragent": "WordDumb/3.32.0 (https://github.com/xxyzz/WordDumb)", "plugin_path": "/Users/jonathantang/Library/Preferences/calibre/plugins/WordDumb.zip", "spacy_model": "en_core_web_md", "create_ww": true, "create_x": true, "asin": "BB1QC7BH59", "acr": "The_Most_Beautiful_Woman_in_Tow", "revision": "dda947cf", "kfx_json": null, "mobi_html": null, "mobi_codec": "utf-8"}', '{"use_pos": true, "search_people": false, "model_size": "md", "zh_wiki_variant": "tw", "mediawiki_api": "", "add_locator_map": true, "preferred_formats": ["KFX", "AZW3", "AZW", "MOBI", "EPUB"], "use_all_formats": false, "minimal_x_ray_count": 1, "choose_format_manually": true, "wiktionary_gloss_lang": "en", "kindle_gloss_lang": "en", "use_gpu": false, "cuda": "cu121", "use_wiktionary_for_kindle": false, "remove_link_styles": false, "python_path": "", "show_change_kindle_ww_lang_warning": false, "ca_wiktionary_difficulty_limit": 5, "cs_wiktionary_difficulty_limit": 5, "da_wiktionary_difficulty_limit": 5, "de_wiktionary_difficulty_limit": 5, "el_wiktionary_difficulty_limit": 5, "en_wiktionary_difficulty_limit": 5, "es_wiktionary_difficulty_limit": 5, "fi_wiktionary_difficulty_limit": 5, "fr_wiktionary_difficulty_limit": 5, "he_wiktionary_difficulty_limit": 5, "hr_wiktionary_difficulty_limit": 5, "it_wiktionary_difficulty_limit": 5, "ja_wiktionary_difficulty_limit": 5, "ko_wiktionary_difficulty_limit": 5, "lt_wiktionary_difficulty_limit": 5, "mk_wiktionary_difficulty_limit": 5, "nl_wiktionary_difficulty_limit": 5, "no_wiktionary_difficulty_limit": 5, "pl_wiktionary_difficulty_limit": 5, "pt_wiktionary_difficulty_limit": 5, "ro_wiktionary_difficulty_limit": 5, "ru_wiktionary_difficulty_limit": 5, "sl_wiktionary_difficulty_limit": 5, "sv_wiktionary_difficulty_limit": 5, "uk_wiktionary_difficulty_limit": 5, "zh_wiktionary_difficulty_limit": 5}']' returned non-zero exit status 1.

Called with args: (ParseJobData(book_id=9, book_path='/Users/jonathantang/Calibre Library/Charles Bukowski/The Most Beautiful Woman in Town (9)/The Most Beautiful Woman in Town - Charles Bukowski.azw3', mi=<calibre.ebooks.metadata.book.base.Metadata object at 0x12ebbcb50>, book_fmt='AZW3', book_lang='en', useragent='WordDumb/3.32.0 (https://github.com/xxyzz/WordDumb)', plugin_path='/Users/jonathantang/Library/Preferences/calibre/plugins/WordDumb.zip', spacy_model='en_core_web_md', create_ww=True, create_x=True, asin='BB1QC7BH59', acr='The_Most_Beautiful_Woman_in_Tow', revision='dda947cf', kfx_json=None, mobi_html=None, mobi_codec='utf-8'),) {'notifications': <queue.Queue object at 0x146516910>, 'abort': <threading.Event at 0x146516b50: unset>, 'log': <calibre.utils.logging.GUILog object at 0x146517550>} Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/Users/jonathantang/Library/Preferences/calibre/plugins/WordDumb.zip/main.py", line 37, in File "/Users/jonathantang/Library/Preferences/calibre/plugins/WordDumb.zip/parse_job.py", line 237, in create_files File "/Users/jonathantang/Library/Preferences/calibre/plugins/WordDumb.zip/parse_job.py", line 763, in load_spacy File "/Users/jonathantang/Library/Preferences/calibre/plugins/worddumb-libs-py3.12/spacy/init.py", line 6, in from .errors import setup_default_warnings File "/Users/jonathantang/Library/Preferences/calibre/plugins/worddumb-libs-py3.12/spacy/errors.py", line 3, in from .compat import Literal File "/Users/jonathantang/Library/Preferences/calibre/plugins/worddumb-libs-py3.12/spacy/compat.py", line 39, in from thinc.api import Optimizer # noqa: F401 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/jonathantang/Library/Preferences/calibre/plugins/worddumb-libs-py3.12/thinc/api.py", line 1, in from .backends import ( File "/Users/jonathantang/Library/Preferences/calibre/plugins/worddumb-libs-py3.12/thinc/backends/init.py", line 17, in from .cupy_ops import CupyOps File "/Users/jonathantang/Library/Preferences/calibre/plugins/worddumb-libs-py3.12/thinc/backends/cupy_ops.py", line 16, in from .numpy_ops import NumpyOps File "thinc/backends/numpy_ops.pyx", line 1, in init thinc.backends.numpy_ops ValueError: numpy.dtype size changed, may indicate binary incompatibility. Expected 96 from C header, got 88 from PyObject

Plugin settings and reproduce steps

After degrading numpy it still didn't work

Generated files, screenshots or videos

No response

xxyzz commented 3 days ago

Delete the "worddumb-libs-py*" folder and let the plugin redownload dependencies. spaCy's developer had released a new version of thinc package that uses numpy v1.

nonuscolling1 commented 21 hours ago

it's working again, thanks. I just removed everything worddumb and then re-installed it, thanks xxyzz and everyone involved in this project