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

Room creation failing with AtttributeError (Internal Server Error) #16822

Closed
NiallBunting opened this issue Jan 17, 2024 · 0 comments
Closed

Comments

@NiallBunting
Copy link

NiallBunting commented Jan 17, 2024

Description

Getting an internal sever error creating a room. I have enabled msc3266 & msc3861 however toggling them seems to make no difference.

See log below.

Request:

{'invite': ['@da0d3b4c-38c0-4893-851d-4ef10f5fcce5:server.co.uk'], 'name': 'hrllo', 'room_alias_name': 'server.2.43d52184-76cb-4f89-a1a4-930af91709d6', 'topic': '2', 'creation_content': {'type': 'server.event'}, 'preset': 'private_chat', 'initial_state': [{'type': 'm.room.avatar', 'content': {'url': 'https://animage.com}}, [{'type': 'm.space.parent', 'state_key': '!cFzDvBxRKXUOgGaehR:server.co.uk', 'content': {'via': ['server.co.uk']}}], {'type': 'm.room.join_rules', 'content': {'join_rule': 'restricted', 'allow': [{'type': 'm.room_membership', 'room_id': '!cFzDvBxRKXUOgGaehR:server.co.uk'}]}}], 'power_level_content_override': {'events_default': 0, 'events': {'m.room.join_rules': 80, 'm.room.name': 60, 'm.room.topic': 60, 'm.room.avatar': 60, 'm.room.pinned_events': 60, 'm.space.child': 70}, 'ban': 60, 'users': {'@serverbot:server.co.uk': 100, '@da0d3b4c-38c0-4893-851d-4ef10f5fcce5:server.co.uk': 90}, 'users_default': 0, 'invite': 0}}

Steps to reproduce

  • use /_matrix/client/v3/createRoom with the above request.

Homeserver

synapse

Synapse Version

1.98.0

Installation Method

I don't know

Database

SQLite

Workers

Single process

Platform

Ubuntu 22.04.03

Configuration

I have enabled msc3266 & msc3861 however toggling them seems to make no difference.

Relevant log output

2024-01-17 13:38:14,540 - synapse.http.server - 140 - ERROR - POST-33 - Failed handle request via 'RoomCreateRestServlet': <XForwardedForRequest at 0x7f08b4b25c30 method='POST' uri='/_matrix/client/v3/createRoom' clientproto='HTTP/1.0' site='8069'>
Traceback (most recent call last):
  File "/opt/venvs/matrix-synapse/lib/python3.10/site-packages/synapse/http/server.py", line 326, in _async_render_wrapper
    callback_return = await self._async_render(request)
  File "/opt/venvs/matrix-synapse/lib/python3.10/site-packages/synapse/http/server.py", line 538, in _async_render
    callback_return = await raw_callback_return
  File "/opt/venvs/matrix-synapse/lib/python3.10/site-packages/synapse/rest/client/room.py", line 165, in on_POST
    return await self._do(request, requester)
  File "/opt/venvs/matrix-synapse/lib/python3.10/site-packages/synapse/rest/client/room.py", line 170, in _do
    room_id, _, _ = await self._room_creation_handler.create_room(
  File "/opt/venvs/matrix-synapse/lib/python3.10/site-packages/synapse/handlers/room.py", line 877, in create_room
    self._validate_room_config(config, visibility)
  File "/opt/venvs/matrix-synapse/lib/python3.10/site-packages/synapse/handlers/room.py", line 1327, in _validate_room_config
    room_encryption_event = any(
  File "/opt/venvs/matrix-synapse/lib/python3.10/site-packages/synapse/handlers/room.py", line 1328, in <genexpr>
    s.get("type", "") == EventTypes.RoomEncryption for s in raw_initial_state
AttributeError: 'list' object has no attribute 'get'

Anything else that would be useful to know?

No response

@NiallBunting NiallBunting changed the title Room creation failing Room creation failing with atttributeerror Jan 17, 2024
@NiallBunting NiallBunting changed the title Room creation failing with atttributeerror Room creation failing with AtttributeError (Internal Server Error) Jan 17, 2024
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

1 participant