forked-synapse/synapse
David Robertson 313581e4e9
Use importlib.metadata to read requirements (#12088)
* Pull runtime dep checks into their own module
* Reimplement `check_requirements` using `importlib`

I've tried to make this clearer. We start by working out which of
Synapse's requirements we need to be installed here and now. I was
surprised that there wasn't an easier way to see which packages were
installed by a given extra.

I've pulled out the error messages into functions that deal with "is
this for an extra or not". And I've rearranged the loop over two
different sets of requirements into one loop with a "must be instaled"
flag.

I hope you agree that this is clearer.

* Test cases
2022-03-01 17:44:41 +00:00
..
_scripts Add a flag to the synapse_review_recent_signups script to ignore and filter appservice users. (#11675) 2022-01-17 16:43:25 +00:00
api Fix PushRuleEvaluator and Filter to work on frozendicts (#12100) 2022-02-28 17:40:24 +00:00
app Use importlib.metadata to read requirements (#12088) 2022-03-01 17:44:41 +00:00
appservice Add support for MSC3202: sending one-time key counts and fallback key usage states to Application Services. (#11617) 2022-02-24 17:55:45 +00:00
config Use importlib.metadata to read requirements (#12088) 2022-03-01 17:44:41 +00:00
crypto Remove HomeServer.get_datastore() (#12031) 2022-02-23 11:04:02 +00:00
events Add module callbacks called for reacting to deactivation status change and profile update (#12062) 2022-03-01 15:00:03 +00:00
federation Remove the unstable /spaces endpoint. (#12073) 2022-02-28 18:33:00 +00:00
groups Remove HomeServer.get_datastore() (#12031) 2022-02-23 11:04:02 +00:00
handlers Add module callbacks called for reacting to deactivation status change and profile update (#12062) 2022-03-01 15:00:03 +00:00
http Remove HomeServer.get_datastore() (#12031) 2022-02-23 11:04:02 +00:00
logging Remove support for the legacy structured logging configuration. (#12008) 2022-02-17 13:32:18 +00:00
metrics Use version string helper from matrix-common (#11979) 2022-02-14 13:12:22 +00:00
module_api Add module callbacks called for reacting to deactivation status change and profile update (#12062) 2022-03-01 15:00:03 +00:00
push Fix PushRuleEvaluator and Filter to work on frozendicts (#12100) 2022-02-28 17:40:24 +00:00
replication Remove HomeServer.get_datastore() (#12031) 2022-02-23 11:04:02 +00:00
res Fetch images when previewing Twitter URLs. (#11985) 2022-02-22 07:11:39 -05:00
rest Remove the unstable /spaces endpoint. (#12073) 2022-02-28 18:33:00 +00:00
server_notices Remove HomeServer.get_datastore() (#12031) 2022-02-23 11:04:02 +00:00
spam_checker_api Remove redundant "coding: utf-8" lines (#9786) 2021-04-14 15:34:27 +01:00
state Faster joins: persist to database (#12012) 2022-03-01 12:49:54 +00:00
static Display an error page during failure of fallback UIA. (#10561) 2021-08-18 08:13:35 -04:00
storage Order in-flight state group queries in biggest-first order (#11610) 2022-03-01 13:41:57 +00:00
streams Remove HomeServer.get_datastore() (#12031) 2022-02-23 11:04:02 +00:00
util Use importlib.metadata to read requirements (#12088) 2022-03-01 17:44:41 +00:00
__init__.py 1.53.0 2022-02-22 11:32:11 +00:00
event_auth.py Remove excess condition on knock->leave check (#11900) 2022-02-22 18:35:01 +00:00
notifier.py Remove HomeServer.get_datastore() (#12031) 2022-02-23 11:04:02 +00:00
py.typed Mark Module API error imports as re-exported and mark Synapse as containing type annotations (#11054) 2021-10-13 08:42:41 +01:00
python_dependencies.py Use importlib.metadata to read requirements (#12088) 2022-03-01 17:44:41 +00:00
server.py Remove HomeServer.get_datastore() (#12031) 2022-02-23 11:04:02 +00:00
types.py Add type hints to synapse/storage/databases/main (#11984) 2022-02-21 16:03:06 +00:00
visibility.py Make the get_global_account_data_by_type_for_user cache be a tree-cache whose key is prefixed with the user ID (#11788) 2022-01-21 08:38:36 +00:00