Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ValueError when BiblicalTermsListSetting is missing from Settings.xml during extract_corpora #643

Open
jcuenod opened this issue Feb 5, 2025 · 3 comments
Labels
bug Something isn't working

Comments

@jcuenod
Copy link

jcuenod commented Feb 5, 2025

I just tried to extract a project that was (for whatever reason) missing the BiblicalTermsListSetting field in the Settings.xml. Adding back the default value made the project extract normally.

@ddaspit ddaspit added the bug Something isn't working label Feb 18, 2025
@ddaspit
Copy link
Collaborator

ddaspit commented Feb 18, 2025

Can you give more information on what happened when you tried to extract the project?

@ddaspit ddaspit removed their assignment Feb 18, 2025
@ddaspit ddaspit moved this from 🆕 New to 🏗 In progress in SIL-NLP Research Feb 18, 2025
@ddaspit ddaspit moved this from 🏗 In progress to 🔖 Ready in SIL-NLP Research Feb 18, 2025
@ddaspit ddaspit changed the title ValueError when BiblicalTermsListSetting is missing from Settings.xml during extra_corpora ValueError when BiblicalTermsListSetting is missing from Settings.xml during extract_corpora Feb 18, 2025
@jcuenod
Copy link
Author

jcuenod commented Feb 18, 2025

Traceback (most recent call last):
File "/home/james/.pyenv/versions/3.8.19/lib/python3.8/runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/home/james/.pyenv/versions/3.8.19/lib/python3.8/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "/home/james/silnlp/silnlp/common/extract_corpora.py", line 105, in
main()
File "/home/james/silnlp/silnlp/common/extract_corpora.py", line 78, in main
check_versification(project_dir)
File "/home/james/silnlp/silnlp/common/paratext.py", line 503, in check_versification
settings = FileParatextProjectSettingsParser(project_dir).parse()
File "/home/james/.cache/pypoetry/virtualenvs/silnlp-0Yv0iW08-py3.8/lib/python3.8/site-packages/machine/corpora/paratext_project_settings_parser_base.py", line 82, in parse
raise ValueError(
ValueError: The BiblicalTermsListSetting element in Settings.xml in project [redacted] is not in the expected format (e.g., Major::BiblicalTerms.xml) but is .

Fwiw, I see #125 which appears to be addressing this issue. I've definitely pulled silnlp since then, but I can't be certain I've updated deps in poetry, so I guess it's plausible that's the issue...

I'll make sure deps are updated when I'm done training a few more models (probably tomorrow), and I'll let you know if it's fixed.

@ddaspit
Copy link
Collaborator

ddaspit commented Feb 19, 2025

Yes, that could definitely be the issue. The Machine dependency might need to be updated to get the fix. Try running poetry install.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: 🔖 Ready
Development

No branches or pull requests

2 participants