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

AttributeError: 'Window' object has no attribute '_disabled_messages' #10

Closed
Rhythmicc opened this issue Jun 18, 2021 · 2 comments
Closed

Comments

@Rhythmicc
Copy link

Rhythmicc commented Jun 18, 2021

I try to run simple.py, and i get following errors: (Platform: Mac OS 11.4 with python 3.8.1)

Task exception was never retrieved
future: <Task finished name='Task-5' coro=<MessagePump.process_messages() done, defined at /Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/message_pump.py:114> exception=AttributeError("'Window' object has no attribute '_closed'")>
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/message_pump.py", line 116, in process_messages
while not self._closed:
AttributeError: 'Window' object has no attribute '_closed'
Traceback (most recent call last):
File "simple.py", line 24, in
app.run()
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/app.py", line 54, in run
asyncio.run(run_app())
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/asyncio/runners.py", line 43, in run
return loop.run_until_complete(main)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/asyncio/base_events.py", line 612, in run_until_complete
return future.result()
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/app.py", line 52, in run_app
await app.process_messages()
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/app.py", line 73, in process_messages
await super().process_messages()
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/message_pump.py", line 124, in process_messages
await self.dispatch_message(message, priority)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/message_pump.py", line 132, in dispatch_message
await self.on_event(message, priority)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/message_pump.py", line 141, in on_event
await dispatch_function(event)
File "simple.py", line 18, in on_startup
await self.view.mount_all(
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/view.py", line 53, in mount_all
await self.mount(widget, slot=slot)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/view.py", line 108, in mount
await self.app.add(widget)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/app.py", line 84, in add
await child.post_message(events.Created(sender=self))
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/widget.py", line 149, in post_message
if not self.check_message_enabled(message):
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/textual/message_pump.py", line 61, in check_message_enabled
return type(message) not in self._disabled_messages
AttributeError: 'Window' object has no attribute '_disabled_messages'

@willmcgugan
Copy link
Collaborator

Did you install it with pip? If you want to try it out, you'll need to check out the repo and run poetry install.

I'll write up a getting started guide soon.

@willmcgugan
Copy link
Collaborator

Fixed in master

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

No branches or pull requests

2 participants