AlynxZhou / showmethekey

Show keys you typed on screen.
https://showmethekey.alynx.one/
Apache License 2.0
329 stars 26 forks source link

Keys ignored if device_name contains \n #21

Closed XMadFoX closed 1 year ago

XMadFoX commented 1 year ago

It breaks parsing:

(showmethekey-gtk:1812744): showmethekey-gtk-WARNING **: 22:39:24.556: Create event error: <data>:1:78: Parse error: scanner: unterminated string constant.

(showmethekey-gtk:1812744): showmethekey-gtk-WARNING **: 22:39:24.556: Create event error: <data>:1:8: Parse error: unexpected identifier `Line2', expected value.

libinput list-devices looks like

...
Device:           Line1
Line2
...

I think I might do PR to fix it

AlynxZhou commented 1 year ago

Well, when I started to write this app, I just decide to output a json per line…Never think about device name contains \n, there are some solutions in my brain, I'll handle tomorrow.

On Sun, Jun 11, 2023, 02:55 MadFox @.***> wrote:

It breaks parsing:

(showmethekey-gtk:1812744): showmethekey-gtk-WARNING **: 22:39:24.556: Create event error: :1:78: Parse error: scanner: unterminated string constant.

(showmethekey-gtk:1812744): showmethekey-gtk-WARNING **: 22:39:24.556: Create event error: :1:8: Parse error: unexpected identifier `Line2', expected value.

libinput list-devices looks like

... Device: Line1 Line2 ...

I think I might do PR to fix it

— Reply to this email directly, view it on GitHub https://github.com/AlynxZhou/showmethekey/issues/21, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACANVR5ZSLW733HYNNUMACTXKS7KXANCNFSM6AAAAAAZB2YXHY . You are receiving this because you are subscribed to this thread.Message ID: @.***>

AlynxZhou commented 1 year ago

I just dropped device name totally.