felixonmars / ydcv

YouDao Console Version - Simple wrapper for Youdao online translate (Chinese <-> English) service API, as an alternative to the StarDict Console Version(sdcv).
GNU General Public License v3.0
506 stars 91 forks source link

[bug] KeyError #59

Closed Freed-Wu closed 2 years ago

Freed-Wu commented 2 years ago
$ sudo pacman -S ydcv
$ ydcv
Traceback (most recent call last):
  File "/usr/bin/ydcv", line 33, in <module>
    sys.exit(load_entry_point('ydcv==0.7', 'console_scripts', 'ydcv')())
  File "/usr/lib/python3.10/site-packages/ydcv.py", line 353, in main
    sec = config["YDCV"]
  File "/usr/lib/python3.10/configparser.py", line 964, in __getitem__
    raise KeyError(key)
KeyError: 'YDCV'
Freed-Wu commented 2 years ago

https://github.com/felixonmars/ydcv#%E6%B3%A8%E6%84%8F I suggest to add a prompt on adding API-key.

Freed-Wu commented 2 years ago

Oh, it should be because the ydcv installed by pacman is older than the latest ydcv.