[BUG] --version选项错误
- Langage dominant
- Python
- Étoiles
- 4.4k
- Forks
- 593
- Métriques de merge des PR
- Aucune PR mergée en 30 j
Description
**问题描述(Question description)**
music-dl --version
命令报错:
> Traceback (most recent call last):
> File "/home/username/.local/bin/music-dl", line 8, in
> sys.exit(main())
> File "/usr/lib/python3/dist-packages/click/core.py", line 1128, in __call__
> return self.main(*args, **kwargs)
> File "/usr/lib/python3/dist-packages/click/core.py", line 1052, in main
> with self.make_context(prog_name, args, **extra) as ctx:
> File "/usr/lib/python3/dist-packages/click/core.py", line 914, in make_context
> self.parse_args(ctx, args)
> File "/usr/lib/python3/dist-packages/click/core.py", line 1370, in parse_args
> value, args = param.handle_parse_result(ctx, opts, args)
> File "/usr/lib/python3/dist-packages/click/core.py", line 2347, in handle_parse_result
> value = self.process_value(ctx, value)
> File "/usr/lib/python3/dist-packages/click/core.py", line 2309, in process_value
> value = self.callback(ctx, self, value)
> File "/usr/lib/python3/dist-packages/click/decorators.py", line 380, in callback
> raise RuntimeError(
> RuntimeError: 'music_dl' is not installed. Try passing 'package_name' instead.
**使用的环境(Environment)**
- 安装方式(Installation method):pip
- music-dl版本(music-dl version):
- 操作系统版本(OS version):ubuntu 22.04
- Python版本(Python version):Python 3.10.6
Guide de contribution
Aucun guide de contribution indexé pour ce dépôt
Piste de recherche
The error occurs when running `music-dl --version`. Look at the entry point in `/home/username/.local/bin/music-dl` and the main function in the click application. Check how the version callback is defined and why it's trying to get package info. The fix likely involves correcting the package name or the way version is retrieved in the click command setup.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- python
- Domaine
- cli
- Type d'issue
- Bug
- Difficulté
- 2/5
- Temps estimé
- 1-3 heures
- Activité
- À l'abandon
- Clarté
- Clairement spécifiée
- Accessibilité débutants
- 65/100