Skip to content

msdl运行报错SyntaxError: f-string: unterminated string #282

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

Open
Quaso2222 opened this issue Jan 10, 2025 · 2 comments
Open

msdl运行报错SyntaxError: f-string: unterminated string #282

Quaso2222 opened this issue Jan 10, 2025 · 2 comments

Comments

@Quaso2222
Copy link

使用conda24创建虚拟环境
conda create -n myenv python=3.11
随后进入环境myenv
cd MindSearch/docker
pip install -e .
msdl
报错如下
(myenv ) [root@localhost MindSearch-main]# msdl
Traceback (most recent call last):
File "/home/software/anaconda3/anaconda/envs/mind/bin/msdl", line 33, in
sys.exit(load_entry_point('msdl', 'console_scripts', 'msdl')())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/software/anaconda3/anaconda/envs/mind/bin/msdl", line 25, in importlib_load_entry_point
return next(matches).load()
^^^^^^^^^^^^^^^^^^^^
File "/home/software/anaconda3/anaconda/envs/mind/lib/python3.11/importlib/metadata/init.py", line 202, in load
module = import_module(match.group('module'))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/software/anaconda3/anaconda/envs/mind/lib/python3.11/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "", line 1204, in _gcd_import
File "", line 1176, in _find_and_load
File "", line 1147, in _find_and_load_unlocked
File "", line 690, in _load_unlocked
File "", line 940, in exec_module
File "", line 241, in call_with_frames_removed
File "/home/LLM/mindsearch/MindSearch-main/docker/msdl/main.py", line 33, in
from msdl.user_interaction import get_user_choices
File "/home/LLM/mindsearch/MindSearch-main/docker/msdl/user_interaction.py", line 187
"name": f"{t(f'SEARCH_ENGINE
{info["key"]}')} ({t('NO_API_KEY_NEEDED') if not info['requires_key'] else t('API_KEY_REQUIRED')})",
^^^
SyntaxError: f-string: unterminated string

@Quaso2222
Copy link
Author

image

@Quaso2222
Copy link
Author

改为 "name": f"""{t(f'SEARCH_ENGINE_{info["key"]}')} ({t('NO_API_KEY_NEEDED') if not info['requires_key'] else t('API_KEY_REQUIRED')})""",后正常

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