summary refs log tree commit diff
path: root/synapse/util/module_loader.py (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Better formatting for config errors from modules (#8874)Richard van der Hoff2020-12-081-6/+58
| | | | | | | | | | The idea is that the parse_config method of extension modules can raise either a ConfigError or a JsonValidationError, and it will be magically turned into a legible error message. There's a few components to it: * Separating the "path" and the "message" parts of a ConfigError, so that we can fiddle with the path bit to turn it into an absolute path. * Generally improving the way ConfigErrors get printed. * Passing in the config path to load_module so that it can wrap any exceptions that get caught appropriately.
* Clarify error message when plugin config parsers raise an error (#8492)Richard van der Hoff2020-10-081-1/+1
| | | | | | | | | This turns: Failed to parse config for 'myplugin': Exception('error message') into: Failed to parse config for 'myplugin': error message.
* Handle `config` not being set for synapse plugin modulesRichard van der Hoff2020-01-121-1/+1
| | | | | Some modules don't need any config, so having to define a `config` property just to keep the loader happy is a bit annoying.
* Fix up some typechecking (#6150)Amber Brown2019-10-021-1/+1
| | | | | | * type checking fixes * changelog
* Fix a bug with saml attribute maps.Richard van der Hoff2019-09-191-1/+19
| | | | | | | | | | | | | Fixes a bug where the default attribute maps were prioritised over user-specified ones, resulting in incorrect mappings. The problem is that if you call SPConfig.load() multiple times, it adds new attribute mappers to a list. So by calling it with the default config first, and then the user-specified config, we would always get the default mappers before the user-specified mappers. To solve this, let's merge the config dicts first, and then pass them to SPConfig.
* Run Black. (#5482)Amber Brown2019-06-201-4/+2
|
* pep8David Baker2017-09-261-0/+1
|
* unnecessary parensDavid Baker2017-09-261-1/+1
|
* Add module_loader.pyDavid Baker2017-09-261-0/+41