promptops / cli

um is a GPT-powered CLI assistant. Ask questions in plain English, get the perfect shell command.
https://promptops.com
GNU General Public License v3.0
122 stars 3 forks source link

Not working with ZSH and oh my zsh #2

Closed 57r4n63r closed 1 year ago

57r4n63r commented 1 year ago

Pretty self explanatory. It looks like it's not working with ZSH and oh my zsh installed. Something about utf-8 codec Selection_259

gilzow commented 1 year ago

ditto. Just installed via brew and very first attempt at using um shows a similar error as @57r4n63r

image
jj-ctrlstack commented 1 year ago

@57r4n63r I think I found the issue, do you mind upgrading and giving it a try.

pip3 install -U git+https://github.com/promptops/cli.git
jj-ctrlstack commented 1 year ago

@gilzow -- if you are willing to try with pip3 using latest, the command I just posted? We can then update the brew version as well.

57r4n63r commented 1 year ago

Looks like the problem is still there.

gilzow commented 1 year ago

just tried. gives an even bigger stack trace:

image
jj-ctrlstack commented 1 year ago

Yikes, can you provide more info of your system - what's your OS + shell that you are using. I wonder if this can be utf-16 encoded.

gilzow commented 1 year ago

macOS 11.7.4

❯ zsh --version
zsh 5.8 (x86_64-apple-darwin20.0)
57r4n63r commented 1 year ago

I'm using Pop!_OS 22.04 LTS, Gnome terminal. zsh 5.8.1 (x86_64-ubuntu-linux-gnu) "Oh my zsh" almost vanilla config Selection_260

jj-ctrlstack commented 1 year ago

Thanks folks, I think it might be related to this issue https://www.zsh.org/mla/users/2011/msg00154.html. Just pushed a workaround until proper fix is in place. Let me know if this works.

gilzow commented 1 year ago

I uninstalled and reinstalled. While it no longer throws an error, it also just hangs. It's been sitting for greater than 5 minutes not doing anything after requesting a command (same as before: um list branches in git)

❯ um --version
0.1.4
jj-ctrlstack commented 1 year ago

Thanks for your patience with this. I think what might be happening is that now it's attempting to index the history but outside the configuration flow we were not showing progress bar. Pushed a fix for this, but you can also run um --config to re-configure.

57r4n63r commented 1 year ago

Seems like it's working fine now. thanks !

gilzow commented 1 year ago

yep, version 0.1.5 is working for me now as well. Thanks!