kovidgoyal / kitty

Cross-platform, fast, feature-rich, GPU based terminal
https://sw.kovidgoyal.net/kitty/
GNU General Public License v3.0
24.15k stars 972 forks source link

Kitty 12.0 breaks image preview. #850

Closed VGrol closed 6 years ago

VGrol commented 6 years ago

Arch Linux 4.18 Kitty 0.12.0 Neofetch 5.0.0

The upgrade to Kitty V12.0 on Arch Linux seemed to have broken image displays via the Kitty protocol. Neofetch configured to display images the 'Kitty' way, is no longer functioning in V12, it instead returns ^[_Gi=1;OK^[\^[_Gi=2;OK^[\0s max. wait)... and then after several seconds it returns. ^[_Gi=1;OK^[\^[_Gi=2;OK^[\0 After which it just drops the Neofetch text without the image.

A rollback to V11.3 results in the problem being resolved.

I'm not exactly certain if this needs to be reporterd here or on the Neofetch repo, Unless the kitty-image display has gotten a major overhaul, I don't think it is a problem with the Neofetch implementation of the kitty image viewer.

kovidgoyal commented 6 years ago

icat still works for me on Arch with kitty 0.12 doesn't neofetch just use icat? How is one supposed to get neofetch to display an image, so I can reproduce?

As does the image display in the diff kitten.

itaton commented 6 years ago

icat does not work for me on Arch with kitty 0.12 (I tried kitty icat image.jpg) I'm getting the same output as VGrol at first and after a couple of seconds when it return, it prints ^[_Gi=1;OK^[\^[_Gi=2;OK^[\This terminal emulator does not support the graphics protocol, use a terminal emulator such as kitty that does support it

I can also confirm that it was working before I upgraded.

Edit: it works with kitty +kitten icat image.jpg, but before the upgrade it also worked without the +kitten

kovidgoyal commented 6 years ago

As I said icat works for me on arch and I can't think of anything that could have changed in 0.12 to break it. The only thing I can think of is a problem in the binaries, as I am running from source. Can one of you check if it works when running from source.

Also, as a workaround, since detection seems to be failing for you, you can use icat --transfer-mode=file to bypass it or if you are over an SSH connection, use icat --transfer-mode=stream

kovidgoyal commented 6 years ago

I tested it with the binary on arch and that also works for me.

itaton commented 6 years ago

kitty icat --transfer-mode=file image.jpg works

Edit: Building from source gives me the same error when using kitty icat image.jpg: ^[_Gi=1;OK^[\^[_Gi=2;OK^[\This terminal emulator does not support the graphics protocol, use a terminal emulator such as kitty that does support it

kovidgoyal commented 6 years ago

You can try a bisect to see which commit is breaking detection. The only two commits I can find that might be relevant are: 0cc008e and d964146

SolitudeSF commented 6 years ago

same here, +kitten icat works, icat doesn't. thats how neofetch invokes icat.

kovidgoyal commented 6 years ago

Ah, that makes sense -- I'll fix that, but neofetch should be changed to use +kitten icat asplain icat is legacy.

SolitudeSF commented 6 years ago

i submitted pr with updated invocation to neofetch

kovidgoyal commented 6 years ago

thanks :)