- Mar 09, 2021
-
-
Patrick Cloke authored
Type hint fixes due to Twisted 21.2.0 adding type hints.
-
Patrick Cloke authored
Properly uses RGBA mode for 1- and 8-bit images with transparency (instead of RBG mode).
-
- Mar 08, 2021
-
-
Jonathan de Jong authored
-
Patrick Cloke authored
Unfortunately this doesn't test re-joining the room since that requires having another homeserver to query over federation, which isn't easily doable in unit tests.
-
- Mar 04, 2021
-
-
Richard van der Hoff authored
This great big stack of commits is a a whole load of hoop-jumping to make it easier to store additional values in login tokens, and then to actually store the SSO Identity Provider in the login token. (Making use of that data will follow in a subsequent PR.)
-
- Mar 03, 2021
-
-
Patrick Cloke authored
-
- Mar 01, 2021
-
-
Patrick Cloke authored
By consuming the response if the headers imply that the content is too large.
-
- Feb 26, 2021
-
-
Tim Leung authored
### Changes proposed in this PR - Add support for the `no_proxy` and `NO_PROXY` environment variables - Internally rely on urllib's [`proxy_bypass_environment`](https://github.com/python/cpython/blob/bdb941be423bde8b02a5695ccf51c303d6204bed/Lib/urllib/request.py#L2519) - Extract env variables using urllib's `getproxies`/[`getproxies_environment`](https://github.com/python/cpython/blob/bdb941be423bde8b02a5695ccf51c303d6204bed/Lib/urllib/request.py#L2488 ) which supports lowercase + uppercase, preferring lowercase, except for `HTTP_PROXY` in a CGI environment This does contain behaviour changes for consumers so making sure these are called out: - `no_proxy`/`NO_PROXY` is now respected - lowercase `https_proxy` is now allowed and taken over `HTTPS_PROXY` Related to #9306 which also uses `ProxyAgent` Signed-off-by:
Timothy Leung <tim95@hotmail.co.uk>
-
Richard van der Hoff authored
... otherwise, we don't get the cookie back.
-
- Feb 25, 2021
-
-
Erik Johnston authored
-
- Feb 24, 2021
-
-
Erik Johnston authored
* Split ShardedWorkerHandlingConfig This is so that we have a type level understanding of when it is safe to call `get_instance(..)` (as opposed to `should_handle(..)`). * Remove special cases in ShardedWorkerHandlingConfig. `ShardedWorkerHandlingConfig` tried to handle the various different ways it was possible to configure federation senders and pushers. This led to special cases that weren't hit during testing. To fix this the handling of the different cases is moved from there and `generic_worker` into the worker config class. This allows us to have the logic in one place and allows the rest of the code to ignore the different cases.
-
- Feb 22, 2021
-
-
Richard van der Hoff authored
`uploads_path` was a thing that was never used; most of it was removed in #6628 but a few vestiges remained.
-
Dirk Klimpel authored
-
Andrew Morgan authored
This PR remove the cache for the `get_shared_rooms_for_users` storage method (the db method driving the experimental "what rooms do I share with this user?" feature: [MSC2666](https://github.com/matrix-org/matrix-doc/pull/2666)). Currently subsequent requests to the endpoint will return the same result, even if your shared rooms with that user have changed. The cache was added in https://github.com/matrix-org/synapse/pull/7785, but we forgot to ensure it was invalidated appropriately. Upon attempting to invalidate it, I found that the cache had to be entirely invalidated whenever a user (remote or local) joined or left a room. This didn't make for a very useful cache, especially for a function that may or may not be called very often. Thus, I've opted to remove it instead of invalidating it.
-
- Feb 19, 2021
-
-
Erik Johnston authored
-
Patrick Cloke authored
-
Andrew Morgan authored
This PR attempts to eliminate unnecessary presence sending work when your local server joins a room, or when a remote server joins a room your server is participating in by processing state deltas in chunks rather than individually. --- When your server joins a room for the first time, it requests the historical state as well. This chunk of new state is passed to the presence handler which, after filtering that state down to only membership joins, will send presence updates to homeservers for each join processed. It turns out that we were being a bit naive and processing each event individually, and sending out presence updates for every one of those joins. Even if many different joins were users on the same server (hello IRC bridges), we'd send presence to that same homeserver for every remote user join we saw. This PR attempts to deduplicate all of that by processing the entire batch of state deltas at once, instead of only doing each join individually. We process the joins and note down which servers need which presence: * If it was a local user join, send that user's latest presence to all servers in the room * If it was a remote user join, send the presence for all local users in the room to that homeserver We deduplicate by inserting all of those pending updates into a dictionary of the form: ``` { server_name1: {presence_update1, ...}, server_name2: {presence_update1, presence_update2, ...} } ``` Only after building this dict do we then start sending out presence updates.
-
Andrew Morgan authored
This PR adds a homeserver config option, `user_directory.prefer_local_users`, that when enabled will show local users higher in user directory search results than remote users. This option is off by default. Note that turning this on doesn't necessarily mean that remote users will always be put below local users, but they should be assuming all other ranking factors (search query match, profile information present etc) are identical. This is useful for, say, University networks that are openly federating, but want to prioritise local students and staff in the user directory over other random users.
-
AndrewFerr authored
Add off-by-default configuration settings to: - disable putting an invitee's profile info in invite events - disable profile lookup via federation Signed-off-by:
Andrew Ferrazzutti <fair@miscworks.net>
-
- Feb 18, 2021
-
-
Rishabh Arya authored
-
Patrick Cloke authored
This reduces the memory usage of previewing media files which end up larger than the `max_spider_size` by avoiding buffering content internally in treq. It also checks the `Content-Length` header in additional places instead of streaming the content to check the body length.
-
- Feb 17, 2021
-
-
Dirk Klimpel authored
-
Richard van der Hoff authored
Apple want to POST the OIDC auth response back to us rather than using query-params; add the necessary support to make that work.
-
- Feb 16, 2021
-
-
Eric Eastwood authored
- Update black version to the latest - Run black auto formatting over the codebase - Run autoformatting according to [`docs/code_style.md `](https://github.com/matrix-org/synapse/blob/80d6dc9783aa80886a133756028984dbf8920168/docs/code_style.md) - Update `code_style.md` docs around installing black to use the correct version
-
Richard van der Hoff authored
Ensure that we lock correctly to prevent multiple concurrent metadata load requests, and generally clean up the way we construct the metadata cache.
-
Patrick Cloke authored
-
Patrick Cloke authored
And convert some inlineDeferreds to async-friendly functions.
-
- Feb 11, 2021
-
-
Patrick Cloke authored
This breaks some people's configurations (if their Client-Server API is not accessed via port 443).
-
Patrick Cloke authored
This has the side-effect of being able to remove use of `inlineCallbacks` in the test-cases for cleaner tracebacks.
-
Patrick Cloke authored
-
- Feb 08, 2021
-
-
Patrick Cloke authored
* Handle the case of lxml not finding a document tree. * Parse the document encoding from the XML tag.
-
- Feb 04, 2021
-
-
Erik Johnston authored
-
Patrick Cloke authored
Fixes some exceptions if the room state isn't quite as expected. If the expected state events aren't found, try to find them in the historical room state. If they still aren't found, fallback to a reasonable, although ugly, value.
-
- Feb 03, 2021
-
-
Richard van der Hoff authored
-
Patrick Cloke authored
Also add a few more IP ranges to the default blacklist.
-
Erik Johnston authored
-
- Feb 02, 2021
-
-
Travis Ralston authored
This could arguably replace the existing admin API for `/members`, however that is out of scope of this change. This sort of endpoint is ideal for moderation use cases as well as other applications, such as needing to retrieve various bits of information about a room to perform a task (like syncing power levels between two places). This endpoint exposes nothing more than an admin would be able to access with a `select *` query on their database.
-
- Feb 01, 2021
-
-
Richard van der Hoff authored
-
Patrick Cloke authored
* Fixes a case where no summary text was returned. * The use of messages_from_person vs. messages_from_person_and_others was tweaked to depend on whether there was 1 sender or multiple senders, not based on if there was 1 room or multiple rooms.
-
Richard van der Hoff authored
There's some prelimiary work here to pull out the construction of a jinja environment to a separate function. I wanted to load the template at display time rather than load time, so that it's easy to update on the fly. Honestly, I think we should do this with all our templates: the risk of ending up with malformed templates is far outweighed by the improved turnaround time for an admin trying to update them.
-