Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'WindowEvent' has no attribute 'replace' #181

Open
hernan3009 opened this issue Apr 18, 2021 · 0 comments
Open

'WindowEvent' has no attribute 'replace' #181

hernan3009 opened this issue Apr 18, 2021 · 0 comments
Assignees
Labels

Comments

@hernan3009
Copy link

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants