Skip to content

Argos fails with RuntimeError: SpaCy cache not initialized #1309

@evgenyrp

Description

@evgenyrp

https://firefox-ci-tc.services.mozilla.com/tasks/egaMXwGgRQiqNLqw3OzKsA/runs/1/logs/live/public/logs/live.log

[task 2025-12-02T20:13:55.253+00:00] ✔ Download and installation successful
[task 2025-12-02T20:13:55.253+00:00] You can now load the package via spacy.load('xx_sent_ud_sm')
[task 2025-12-02T20:13:55.253+00:00] 
[task 2025-12-02T20:13:55.523+00:00]   0%|          | 0/1012 [00:00<?, ?it/s][stanza] Language en package default expects mwt, which has been added
[task 2025-12-02T20:13:55.921+00:00] Traceback (most recent call last):
[task 2025-12-02T20:13:55.922+00:00]   File "/usr/local/lib/python3.10/dist-packages/argostranslate/sbd.py", line 91, in __init__
[task 2025-12-02T20:13:55.922+00:00]     self.stanza_pipeline = stanza.Pipeline(
[task 2025-12-02T20:13:55.922+00:00]   File "/usr/local/lib/python3.10/dist-packages/stanza/pipeline/core.py", line 252, in __init__
[task 2025-12-02T20:13:55.922+00:00]     download_models(download_list,
[task 2025-12-02T20:13:55.922+00:00]   File "/usr/local/lib/python3.10/dist-packages/stanza/resources/common.py", line 540, in download_models
[task 2025-12-02T20:13:55.922+00:00]     request_file(
[task 2025-12-02T20:13:55.922+00:00]   File "/usr/local/lib/python3.10/dist-packages/stanza/resources/common.py", line 159, in request_file
[task 2025-12-02T20:13:55.922+00:00]     assert_file_exists(path, md5, alternate_md5)
[task 2025-12-02T20:13:55.922+00:00]   File "/usr/local/lib/python3.10/dist-packages/stanza/resources/common.py", line 112, in assert_file_exists
[task 2025-12-02T20:13:55.922+00:00]     raise ValueError("md5 for %s is %s, expected %s" % (path, file_md5, md5))
[task 2025-12-02T20:13:55.922+00:00] ValueError: md5 for /builds/worker/stanza_resources/en/tokenize/combined.pt is 915a830798c75eb3d2b58acde1e40721, expected 89a9c52688ac0ea655ee9f5388e61fe9
[task 2025-12-02T20:13:55.922+00:00] 
[task 2025-12-02T20:13:55.922+00:00] During handling of the above exception, another exception occurred:
[task 2025-12-02T20:13:55.922+00:00] 
[task 2025-12-02T20:13:55.922+00:00] Traceback (most recent call last):
[task 2025-12-02T20:13:55.922+00:00]   File "/builds/worker/checkouts/vcs/pipeline/eval/final_eval.py", line 535, in <module>
[task 2025-12-02T20:13:55.923+00:00]     EvalsRunner(Config()).run()
[task 2025-12-02T20:13:55.923+00:00]   File "/builds/worker/checkouts/vcs/pipeline/eval/final_eval.py", line 380, in run
[task 2025-12-02T20:13:55.923+00:00]     for metric, metas in self.translate(src, trg).items():
[task 2025-12-02T20:13:55.923+00:00]   File "/builds/worker/checkouts/vcs/pipeline/eval/final_eval.py", line 447, in translate
[task 2025-12-02T20:13:55.923+00:00]     translations = translator.translate(source_texts)
[task 2025-12-02T20:13:55.923+00:00]   File "/builds/worker/checkouts/vcs/pipeline/eval/translators.py", line 274, in translate
[task 2025-12-02T20:13:55.923+00:00]     return [translate.translate(text, self.src, self.trg) for text in tqdm(texts)]
[task 2025-12-02T20:13:55.923+00:00]   File "/builds/worker/checkouts/vcs/pipeline/eval/translators.py", line 274, in <listcomp>
[task 2025-12-02T20:13:55.923+00:00]     return [translate.translate(text, self.src, self.trg) for text in tqdm(texts)]
[task 2025-12-02T20:13:55.923+00:00]   File "/usr/local/lib/python3.10/dist-packages/argostranslate/translate.py", line 719, in translate
[task 2025-12-02T20:13:55.924+00:00]     translation = get_translation_from_codes(from_code, to_code)
[task 2025-12-02T20:13:55.924+00:00]   File "/usr/local/lib/python3.10/dist-packages/argostranslate/translate.py", line 703, in get_translation_from_codes
[task 2025-12-02T20:13:55.924+00:00]     from_lang = get_language_from_code(from_code)
[task 2025-12-02T20:13:55.924+00:00]   File "/usr/local/lib/python3.10/dist-packages/argostranslate/translate.py", line 687, in get_language_from_code
[task 2025-12-02T20:13:55.924+00:00]     return next(filter(lambda x: x.code == code, get_installed_languages()), None)
[task 2025-12-02T20:13:55.924+00:00]   File "/usr/local/lib/python3.10/dist-packages/argostranslate/translate.py", line 586, in get_installed_languages
[task 2025-12-02T20:13:55.925+00:00]     PackageTranslation(from_lang, to_lang, pkg)
[task 2025-12-02T20:13:55.925+00:00]   File "/usr/local/lib/python3.10/dist-packages/argostranslate/translate.py", line 168, in __init__
[task 2025-12-02T20:13:55.925+00:00]     self.sentencizer = StanzaSentencizer(pkg)
[task 2025-12-02T20:13:55.925+00:00]   File "/usr/local/lib/python3.10/dist-packages/argostranslate/sbd.py", line 107, in __init__
[task 2025-12-02T20:13:55.925+00:00]     self._init_spacy_fallback()
[task 2025-12-02T20:13:55.925+00:00]   File "/usr/local/lib/python3.10/dist-packages/argostranslate/sbd.py", line 74, in _init_spacy_fallback
[task 2025-12-02T20:13:55.925+00:00]     raise RuntimeError("SpaCy cache not initialized")
[task 2025-12-02T20:13:55.925+00:00] RuntimeError: SpaCy cache not initialized

Metadata

Metadata

Assignees

No one assigned

    Labels

    evalsIssues related to model evaluations

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions