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

Editing bug? #168

Closed
gpythomas opened this issue Dec 27, 2024 · 1 comment · Fixed by #167
Closed

Editing bug? #168

gpythomas opened this issue Dec 27, 2024 · 1 comment · Fixed by #167
Labels
bug Something isn't working
Milestone

Comments

@gpythomas
Copy link

When trying to edit the very first message of a scenario (i.e., double click, edit, and press enter), the scenario crashes (the interface return to the home menu) and the following error message is printed to console:

server.py           :242  2024-12-26 22:50:37,738 connection handler failed
Traceback (most recent call last):
  File "D:\talemate-0.28.0\talemate_env\Lib\site-packages\websockets\legacy\server.py", line 240, in handler
    await self.ws_handler(self)
  File "D:\talemate-0.28.0\talemate_env\Lib\site-packages\websockets\legacy\server.py", line 1186, in _ws_handler
    return await cast(
           ^^^^^^^^^^^
  File "D:\talemate-0.28.0\src\talemate\server\api.py", line 217, in websocket_endpoint
    await asyncio.gather(main_task, send_messages_task, send_status_task, send_client_bootstraps_task, test_connection_task)
  File "C:\Program Files\Python311\Lib\asyncio\tasks.py", line 349, in __wakeup
    future.result()
  File "C:\Program Files\Python311\Lib\asyncio\tasks.py", line 277, in __step
    result = coro.send(None)
             ^^^^^^^^^^^^^^^
  File "D:\talemate-0.28.0\src\talemate\server\api.py", line 184, in handle_messages
    handler.edit_message(data.get("id"), data.get("text"))
  File "D:\talemate-0.28.0\src\talemate\server\websocket_server.py", line 820, in edit_message
    if editor.enabled and message.typ == "character":
                          ^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'typ'

As far as I can tell, this only happens with the first message.

@vegu-ai-tools vegu-ai-tools added the bug Something isn't working label Dec 28, 2024
@vegu-ai-tools vegu-ai-tools added this to the 0.29.0 milestone Dec 28, 2024
@vegu-ai-tools
Copy link
Contributor

Thanks for the report, will take a look

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants