rudis
407695e37a
client: don't log warning in State() when StateStore is set ( #249 )
...
State logs a warning that ClearCachedMembers() fails even when nil is
returned as error. Looks like this was forgotten in 581aa80 .
2024-06-30 12:30:44 +03:00
Tulir Asokan
5daf7a74a3
client: parse event content in Members
2024-06-25 21:29:48 +03:00
Tulir Asokan
59b99dee70
bridgev2: add remote->matrix room tagging and muting interfaces
2024-06-20 14:53:18 +03:00
Tulir Asokan
8b7a3ea230
client: use MSC3916 endpoints for config and preview_url too
2024-06-16 23:29:14 +03:00
Tulir Asokan
f7de98ba77
client: add backwards-compatibility for MakeFullRequest
2024-06-16 13:11:21 +03:00
Tulir Asokan
ef97d96754
client: use authenticated media download endpoint if cached spec versions say it's supported
2024-06-15 20:19:48 +03:00
Tulir Asokan
b959fbf737
client: return *http.Response in MakeFullRequest
2024-06-15 20:18:40 +03:00
Tulir Asokan
3b55fedc17
client: cache spec versions supported by server
2024-06-15 20:16:19 +03:00
Tulir Asokan
a44362dc71
client: stop using MakeFullRequest unnecessarily
2024-06-15 20:15:06 +03:00
Tulir Asokan
a5fbfe2692
Merge branch 'master' into tulir/hicli
2024-06-15 14:25:35 +03:00
Tulir Asokan
5af319fe3f
client: add support for retrying requests with seekable readers
2024-06-12 21:13:51 +03:00
Tulir Asokan
f9dccaaea0
Merge pull request #213 from mautrix/bridgev2
...
Bridge architecture v2
2024-06-10 22:25:49 +03:00
Nick Mills-Barrett
9c77bffa43
Add Client.DefaultHTTPBackoff
2024-06-10 11:49:30 +01:00
Nick Mills-Barrett
92de4a8a51
Add ReqSync.Client field
2024-06-10 09:46:48 +01:00
Nick Mills-Barrett
2580ef78d7
Add FullRequest.BackoffDuration field
2024-06-10 09:46:38 +01:00
Tulir Asokan
2b78b75885
Add beeper streaming flag to sync requests
2024-05-31 14:54:01 +03:00
Sumner Evans
57f6cd89e3
(*Client).Download: return entire response instead of just body
...
Signed-off-by: Sumner Evans <sumner.evans@automattic.com>
2024-05-29 09:55:17 -06:00
Tulir Asokan
3c7b3e13ef
Add initial user and room metadata support
2024-05-28 20:49:23 +03:00
Tulir Asokan
881879ea0a
Do first sync with timeout 0
2024-05-26 00:58:26 +03:00
Nick Mills-Barrett
9917b3ad3c
Add UpdateRequestOnRetry client hook
...
Enables modifying the request object between retries, eg. to switch
contexts after cancel.
2024-05-22 10:18:42 +01:00
Nick Mills-Barrett
78f5e4373b
Pass error to Client.ResponseHook
2024-05-14 19:01:51 +01:00
Toni Spets
898b235a84
Allow overriding http.Client with FullRequest
2024-04-02 13:59:48 +03:00
Tulir Asokan
94246ffc85
Drop maulogger support
2024-03-11 20:36:06 +02:00
Tulir Asokan
581aa80155
Fix some error logs
2024-02-23 21:12:08 +02:00
Sumner Evans
5e73f1674a
verification: add CancelVerification to interface
...
Signed-off-by: Sumner Evans <sumner@beeper.com>
2024-02-18 19:26:12 -07:00
Sumner Evans
990b623244
pre-commit: prevent literal HTTP methods
...
Signed-off-by: Sumner Evans <sumner@beeper.com>
2024-02-15 21:26:29 -07:00
Sumner Evans
582ce5de49
verificationhelper/qrcode: begin implementing flow
...
Signed-off-by: Sumner Evans <sumner@beeper.com>
2024-02-09 11:50:13 -07:00
Toni Spets
b131dab9de
Allow any UI auth for uploading cross signing keys
...
Fix endless loop with UI auth causing 401 when uploading keys. Use any
type for key backup setup request auth data so that unmarshaled objects
can be used that have signatures embedded.
Generating keys will now also return them if we also want to setup key
backup without storing the keys in-between.
2024-02-06 13:39:53 +02:00
Toni Spets
11c2907f2e
Database level support for key backup versioning
...
This doesn't plumb anything in yet but adds the columns and types for an
external implementation.
Key backup version is now typed.
2024-02-01 13:22:32 +02:00
Sumner Evans
385449c9cc
responses: make key backup structs generic over {session,auth}_data
...
Also update the Client to specify the types
Signed-off-by: Sumner Evans <sumner@beeper.com>
2024-01-18 09:17:18 -07:00
Sumner Evans
4020e9c2ea
client: add key backup functions
...
Signed-off-by: Sumner Evans <sumner@beeper.com>
2024-01-17 08:15:58 -07:00
Tulir Asokan
308e3583b0
Add contexts to event handlers
2024-01-13 18:56:12 +02:00
Tulir Asokan
25bc36bc7a
Add more contexts everywhere
2024-01-07 22:45:02 +02:00
Joakim Recht
02e4140236
Make funcs in the SyncStore interface return errors
...
This should have been done in #144 , but I forgot it. When context is being propagated, the context might be cancelled at any point, which will result in an error that needs to be handled.
2023-12-22 12:56:45 +01:00
Joakim Recht
753cdb2e1c
Add context parameter to all client and bridge API functions ( #144 )
2023-12-15 16:23:31 +02:00
Tulir Asokan
26b2e2e590
Use new retryafter utility
2023-09-06 19:09:35 +03:00
vurpo
4639f0c9c4
Retries for media fetch ( #138 )
...
* Retries for media fetch
* Code style fixes
* Don't close response body on media fetch
2023-07-07 16:54:24 +03:00
Sumner Evans
13edf5920c
client/logging: only log request end, log errors consistently
...
Signed-off-by: Sumner Evans <sumner@beeper.com>
Co-authored-by: Tulir Asokan <tulir@maunium.net>
2023-06-27 09:18:20 -06:00
Tulir Asokan
d8b15c18dc
Adjust handling download errors
2023-06-23 15:10:06 +03:00
Fusl
6c3dccafee
properly handle http errors inside download method
2023-06-19 21:27:17 +00:00
Tulir Asokan
c710d4aa8f
Deprecate MSC2716 methods and add Beeper batch send methods
2023-06-19 01:24:44 +03:00
Tulir Asokan
9eaf5efae8
Move more functions out of Client
2023-06-16 14:23:33 +03:00
Tulir Asokan
b723a36ec1
Make ParseErrorResponse public
2023-06-14 14:46:59 +03:00
Tulir Asokan
2c9b28c84d
Stabilize async uploads ( #130 )
2023-06-10 16:25:31 +03:00
Tulir Asokan
560407b794
Stabilize MSC2659 support
2023-05-05 14:46:27 +03:00
Tulir Asokan
8bbee71f1c
Log server request IDs with responses
2023-05-01 17:12:30 +03:00
Tulir Asokan
a5e88d0643
Clear cached memberships when fetching full member list
2023-04-20 22:05:16 +03:00
Tulir Asokan
7f0f2ed372
Update state store with initial state in CreateRoom
2023-04-10 16:51:57 +03:00
Tulir Asokan
8e54781d86
Don't log warning for all failed parsing in state store
2023-04-10 13:06:36 +03:00
vurpo
5561ab7cc1
Add method for setting custom user profile fields ( #124 )
2023-04-05 13:03:47 +03:00