Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Fix missing field in AS documentation #14845

Merged
merged 2 commits into from
Jan 16, 2023
Merged

Fix missing field in AS documentation #14845

merged 2 commits into from
Jan 16, 2023

Commits on Jan 13, 2023

  1. Fix missing field in AS documentation

    The [AS Configuration Snippet](https://matrix-org.github.io/synapse/latest/application_services.html) is missing `id` field, without it Synapse will fail to load:
    
    ```
    synapse-synapse-main-0 synapse 2023-01-13 23:05:25,450 - synapse.storage.databases - 84 - INFO - main - [database config 'master']: Starting 'main' database
    synapse-synapse-main-0 synapse 2023-01-13 23:05:25,452 - synapse.config.appservice - 79 - ERROR - main - Failed to load appservice from '/as/synapse-hookshot-as/registration.yaml'
    synapse-synapse-main-0 synapse 2023-01-13 23:05:25,452 - synapse.config.appservice - 80 - ERROR - main - "Required string field: 'id' (/as/synapse-hookshot-as/registration.yaml)"
    synapse-synapse-main-0 synapse Traceback (most recent call last):
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/config/appservice.py", line 57, in load_appservices
    synapse-synapse-main-0 synapse     appservice = _load_appservice(hostname, yaml.safe_load(f), config_file)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/config/appservice.py", line 91, in _load_appservice
    synapse-synapse-main-0 synapse     raise KeyError(
    synapse-synapse-main-0 synapse KeyError: "Required string field: 'id' (/as/synapse-hookshot-as/registration.yaml)"
    synapse-synapse-main-0 synapse 2023-01-13 23:05:25,452 - synapse.app._base - 207 - ERROR - main - Exception during startup
    synapse-synapse-main-0 synapse Traceback (most recent call last):
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/app/homeserver.py", line 340, in setup
    synapse-synapse-main-0 synapse     hs.setup()
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/server.py", line 310, in setup
    synapse-synapse-main-0 synapse     self.datastores = Databases(self.DATASTORE_CLASS, self)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/__init__.py", line 93, in __init__
    synapse-synapse-main-0 synapse     main = main_store_class(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/__init__.py", line 139, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/events_bg_updates.py", line 98, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/devices.py", line 1584, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/devices.py", line 89, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/roommember.py", line 1494, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/room.py", line 1827, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/room.py", line 1365, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/room.py", line 119, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/registration.py", line 2158, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/presence.py", line 67, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/presence.py", line 48, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/transactions.py", line 73, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/state.py", line 666, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/state.py", line 82, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/state.py", line 470, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/event_federation.py", line 2007, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/media_repository.py", line 148, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/media_repository.py", line 68, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/push_rule.py", line 330, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/event_push_actions.py", line 1938, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/metrics.py", line 68, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/event_push_actions.py", line 249, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/end_to_end_keys.py", line 1181, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/search.py", line 426, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/search.py", line 137, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/account_data.py", line 64, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/push_rule.py", line 114, in __init__
    synapse-synapse-main-0 synapse     super().__init__(database, db_conn, hs)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/storage/databases/main/appservice.py", line 76, in __init__
    synapse-synapse-main-0 synapse     self.services_cache = load_appservices(
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/config/appservice.py", line 57, in load_appservices
    synapse-synapse-main-0 synapse     appservice = _load_appservice(hostname, yaml.safe_load(f), config_file)
    synapse-synapse-main-0 synapse   File "/usr/local/lib/python3.9/site-packages/synapse/config/appservice.py", line 91, in _load_appservice
    synapse-synapse-main-0 synapse     raise KeyError(
    synapse-synapse-main-0 synapse KeyError: "Required string field: 'id' (/as/synapse-hookshot-as/registration.yaml)"
    synapse-synapse-main-0 synapse ******************************************************************************
    synapse-synapse-main-0 synapse  Error during initialisation:
    synapse-synapse-main-0 synapse     "Required string field: 'id' (/as/synapse-hookshot-as/registration.yaml)"
    synapse-synapse-main-0 synapse  There may be more information in the logs.
    synapse-synapse-main-0 synapse ******************************************************************************
    ```
    Arkaniad authored Jan 13, 2023
    Configuration menu
    Copy the full SHA
    f49a614 View commit details
    Browse the repository at this point in the history

Commits on Jan 16, 2023

  1. Changelog

    David Robertson committed Jan 16, 2023
    Configuration menu
    Copy the full SHA
    e2d21ff View commit details
    Browse the repository at this point in the history