npiv / chatblade

A CLI Swiss Army Knife for ChatGPT
GNU General Public License v3.0
2.58k stars 92 forks source link

error with version flag #86

Open gzheng92 opened 5 months ago

gzheng92 commented 5 months ago

I'm using the latest version of chatblade from homebrew (although the issue was there with 0.4.0_2 as well). Attempting to check the version gives the following response.

I suspect (no prof though) it's something to do with python 3.12?

➜ chatblade --version
/opt/homebrew/Cellar/chatblade/0.4.0_3/libexec/lib/python3.12/site-packages/chatblade/session.py:13: SyntaxWarning: invalid escape sequence '\.'
  re.sub("\.yaml\Z", "", os.path.basename(sess_path))
Traceback (most recent call last):
  File "/opt/homebrew/bin/chatblade", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/opt/homebrew/Cellar/chatblade/0.4.0_3/libexec/lib/python3.12/site-packages/chatblade/__main__.py", line 5, in main
    cli.cli()
  File "/opt/homebrew/Cellar/chatblade/0.4.0_3/libexec/lib/python3.12/site-packages/chatblade/cli.py", line 155, in cli
    version = dist.get_option_dict('metadata')['version'][1]
              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^
KeyError: 'version'