'WindowEvent' has no attribute 'replace'
hernan3009 opened this issue · 0 comments
hernan3009 commented
Hi,
I am trying to automatically perform font size changes in the terminal when its window is anyhow resized. I get AtributeError with this short code
from i3ipc import Connection, Event
import i3ipc
i3 = Connection()
def is_resizing(i3, e):
print("lets see")
return
i3.on(i3ipc.WindowEvent, is_resizing)
i3.main()
It returns
File "/home/XXXXX/Aplicaciones/miniconda3/lib/python3.9/site-packages/i3ipc/connection.py", line 375, in on
event = event.replace('-', '_')
AttributeError: type object 'WindowEvent' has no attribute 'replace'
I tried to comment the line no. 375 but similar errors still remains.
Is this a bug or I am doing something wrong?
Thanks!
Note: The same happens for WorkspaceEvent
sway version 1.5.1
Fedora 34