Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.
 
 
 
 
 
 

44 рядки
1.6 KiB

  1. # Copyright 2021 The Matrix.org Foundation C.I.C.
  2. #
  3. # Licensed under the Apache License, Version 2.0 (the "License");
  4. # you may not use this file except in compliance with the License.
  5. # You may obtain a copy of the License at
  6. #
  7. # http://www.apache.org/licenses/LICENSE-2.0
  8. #
  9. # Unless required by applicable law or agreed to in writing, software
  10. # distributed under the License is distributed on an "AS IS" BASIS,
  11. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. # See the License for the specific language governing permissions and
  13. # limitations under the License.
  14. from synapse.config._base import Config
  15. from synapse.types import JsonDict
  16. class ExperimentalConfig(Config):
  17. """Config section for enabling experimental features"""
  18. section = "experimental"
  19. def read_config(self, config: JsonDict, **kwargs):
  20. experimental = config.get("experimental_features") or {}
  21. # MSC2858 (multiple SSO identity providers)
  22. self.msc2858_enabled: bool = experimental.get("msc2858_enabled", False)
  23. # MSC3026 (busy presence state)
  24. self.msc3026_enabled: bool = experimental.get("msc3026_enabled", False)
  25. # MSC2716 (backfill existing history)
  26. self.msc2716_enabled: bool = experimental.get("msc2716_enabled", False)
  27. # MSC2285 (hidden read receipts)
  28. self.msc2285_enabled: bool = experimental.get("msc2285_enabled", False)
  29. # MSC3244 (room version capabilities)
  30. self.msc3244_enabled: bool = experimental.get("msc3244_enabled", False)
  31. # MSC3266 (room summary api)
  32. self.msc3266_enabled: bool = experimental.get("msc3266_enabled", False)