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

The anserini library does not load on Windows when the user name is in Chinese. #1880

Open
xzzvsxd opened this issue May 5, 2024 · 0 comments

Comments

@xzzvsxd
Copy link

xzzvsxd commented May 5, 2024

ERROR IS :
Traceback (most recent call last):
File "", line 189, in _run_module_as_main
File "", line 112, in get_module_details
File "C:\Users\李星宇\AppData\Local\Programs\Python\Python312\Lib\site-packages\pyserini\index_init
.py", line 21, in
from .lucene.base import Document, Generator, IndexTerm, Posting, IndexReader
File "C:\Users\李星宇\AppData\Local\Programs\Python\Python312\Lib\site-packages\pyserini\index\lucene_init
.py", line 17, in
from .base import Document, Generator, IndexTerm, Posting, IndexReader
File "C:\Users\李星宇\AppData\Local\Programs\Python\Python312\Lib\site-packages\pyserini\index\lucene_base.py", line 30, in
from pyserini.analysis import get_lucene_analyzer, JAnalyzer, JAnalyzerUtils
File "C:\Users\李星宇\AppData\Local\Programs\Python\Python312\Lib\site-packages\pyserini\analysis_init
.py", line 17, in
from ._base import get_lucene_analyzer, Analyzer, JAnalyzer, JAnalyzerUtils, JDefaultEnglishAnalyzer, JWhiteSpaceAnalyzer
File "C:\Users\李星宇\AppData\Local\Programs\Python\Python312\Lib\site-packages\pyserini\analysis_base.py", line 23, in
JAnalyzer = autoclass('org.apache.lucene.analysis.Analyzer')
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\李星宇\AppData\Local\Programs\Python\Python312\Lib\site-packages\jnius\reflect.py", line 209, in autoclass
c = find_javaclass(clsname)
^^^^^^^^^^^^^^^^^^^^^^^
File "jnius\jnius_export_func.pxi", line 22, in jnius.find_javaclass
File "jnius\jnius_utils.pxi", line 79, in jnius.check_exception
jnius.JavaException: JVM exception occurred: org/apache/lucene/analysis/Analyzer java.lang.NoClassDefFoundError

CURE IS :
Changing the path to the jar package that stores anserini to plain English will eliminate the error, but it will affect the experience.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant