Paul "LeoNerd" Evans
5f49914dee
Avoid cyclic dependency in handler setup
2014-12-10 21:17:48 +00:00
Paul "LeoNerd" Evans
1a75ff5c23
Hook up the event stream to typing notifications
2014-12-10 21:01:49 +00:00
Paul "LeoNerd" Evans
4006d58335
Store serial numbers per room for typing event stream purposes
2014-12-10 20:48:25 +00:00
Paul "LeoNerd" Evans
9eb819e828
First hack at implementing timeouts in typing notification handler
2014-12-10 19:39:01 +00:00
Erik Johnston
4c682143c8
.from_string() no longer takes a HS
2014-12-10 18:00:49 +00:00
Erik Johnston
02e4c18171
Remove dead code
2014-12-10 18:00:36 +00:00
Erik Johnston
b245ee34ed
Add some basic event validation
2014-12-10 17:59:47 +00:00
Mark Haines
4f37c0ea9d
Merge branch 'develop' into media_repository
2014-12-10 16:55:06 +00:00
Mark Haines
61fc37e467
Merge branch 'develop' into media_repository
2014-12-10 16:14:17 +00:00
Mark Haines
2d265ef3bd
import Image as PIL.Image.
2014-12-10 16:09:18 +00:00
Erik Johnston
1d2a0040cf
Fix bug where we clobbered old state group values
2014-12-10 15:55:03 +00:00
Mark Haines
e5275d856e
Get the code actually working
2014-12-10 15:46:18 +00:00
Mark Haines
cc84d3ea78
Thumbnail uploaded and cached images
2014-12-10 15:40:52 +00:00
Erik Johnston
cabead6194
Actually fix bug when uploading state with empty state_key
2014-12-10 14:49:52 +00:00
Erik Johnston
02db7eb209
Fix bug when uploading state with empty state_key
2014-12-10 14:02:48 +00:00
Erik Johnston
aae8a37e63
Merge branch 'develop' of github.com:matrix-org/synapse into events_refactor
2014-12-10 13:18:40 +00:00
Erik Johnston
02db1fd2e7
Fix AttributeError
2014-12-10 12:00:05 +00:00
Erik Johnston
018443cb59
Make depth increase.
2014-12-10 11:59:53 +00:00
Erik Johnston
102d2373b4
Add __str__ to FrozenEvent
2014-12-10 11:38:08 +00:00
Erik Johnston
95aa903ffa
Try and figure out how and why signatures are being changed.
2014-12-10 11:37:47 +00:00
Matthew Hodgson
0f4dcab238
turn back on per-request transaction retries, so that every time we try to hit a dead server we actually end up hammering 5 times :|
2014-12-10 10:28:27 +00:00
Erik Johnston
b8d30899b1
Code style.
2014-12-10 10:16:09 +00:00
Matthew Hodgson
71da2bed55
plateau retries after 1h
2014-12-10 00:18:44 +00:00
Matthew Hodgson
faf12b64f8
add errbacks to enqueue_pdu deferreds; change logging for failed federation sends to warn rather than exception
2014-12-10 00:12:51 +00:00
Matthew Hodgson
2b1acb7671
squidge to 79 columns as per pep8
2014-12-10 00:03:55 +00:00
Erik Johnston
008303b245
PEP8
2014-12-09 14:49:11 +00:00
Erik Johnston
5eca288d28
Fix joining from an invite
2014-12-09 14:47:27 +00:00
Erik Johnston
aa3f66cf7f
Change the way we implement get_events to be less sucky
2014-12-09 13:35:26 +00:00
Erik Johnston
bc6564bac0
Add PEP8 newlines
2014-12-09 11:01:44 +00:00
Erik Johnston
8c48450682
Add PEP8 newlines
2014-12-09 10:58:31 +00:00
Erik Johnston
1c8ee06877
Remove unused snapshot
2014-12-09 10:53:34 +00:00
Erik Johnston
4e57943cc5
Remove unused import
2014-12-09 10:51:36 +00:00
Matthew Hodgson
8529fba02d
fix a million stupid bugs and make it actually work
2014-12-08 19:34:51 +00:00
Erik Johnston
609c31e8df
More bug fixes
2014-12-08 17:50:56 +00:00
Matthew Hodgson
0d3fa1ac6e
add a write-through cache on the retry schedule
2014-12-08 17:48:57 +00:00
Erik Johnston
ee3df06183
More bug fixes
2014-12-08 14:50:48 +00:00
Erik Johnston
ba3d1e2fc0
Remove unused import
2014-12-08 12:01:25 +00:00
Erik Johnston
e8323b9e34
More bug fixes
2014-12-08 10:16:18 +00:00
Erik Johnston
a295a3c691
Fix registration
2014-12-08 09:24:37 +00:00
Erik Johnston
721482c83e
Add forgotten file
2014-12-08 09:10:12 +00:00
Erik Johnston
d044121168
Various typos and bug fixes.
2014-12-08 09:08:26 +00:00
Matthew Hodgson
9c43b258ec
actually reset retry schedule if we can successfuly talk to it
2014-12-08 00:17:12 +00:00
Matthew Hodgson
5cd43d4b9f
fix stupid syntax thinkos
2014-12-07 23:44:16 +00:00
Matthew Hodgson
aed62a3583
track replication destination health, and perform exponential back-off when sending transactions. does *not* yet retry transactions, but drops them on the floor if waiting for a server to recover.
2014-12-07 02:26:07 +00:00
Mark Haines
a953be097f
Add a method field to thumbnail storage
2014-12-05 16:31:56 +00:00
Erik Johnston
6630e1b579
Start making more things use EventContext rather than event.*
2014-12-05 16:20:48 +00:00
Mark Haines
0363820122
Add a class for generating thumbnails using PIL
2014-12-05 16:12:37 +00:00
Erik Johnston
c5c32266d8
Merge branch 'develop' of github.com:matrix-org/synapse into events_refactor
2014-12-04 15:58:24 +00:00
Erik Johnston
c31dba86ec
Convert rest and handlers to use new event structure
2014-12-04 15:50:01 +00:00
Mark Haines
c01fd5573c
Implement download support for media_repository
2014-12-04 14:22:31 +00:00
Erik Johnston
5d7c9ab789
Begin converting things to use the new Event structure
2014-12-04 11:27:59 +00:00
Paul "LeoNerd" Evans
f5d2514fc0
@log_function on PresenceStream's get_new_events_for_user()
2014-12-03 19:48:14 +00:00
Paul "LeoNerd" Evans
52f1d3c886
Store any incoming presence push in the local cache anyway, even if there's no interested observers (yet *hint*) (SYN-115)
2014-12-03 19:06:24 +00:00
Erik Johnston
797193283e
Bump changes and version
2014-12-03 18:01:47 +00:00
Erik Johnston
75b4329aaa
WIP for new way of managing events.
2014-12-03 16:07:21 +00:00
Erik Johnston
6941a19715
Merge branch 'develop' of github.com:matrix-org/synapse into events_refactor
2014-12-03 11:56:49 +00:00
Erik Johnston
d06dfc70b0
Fix bug where did not always resolve all the deferreds in _attempt_new_transaction
2014-12-03 11:50:23 +00:00
Paul "LeoNerd" Evans
66b0596b7a
Don't log synapse.storage at DEBUG level when under -v; require -v -v for that
2014-12-02 22:28:18 +00:00
Paul "LeoNerd" Evans
10eb8f070c
Workaround for non-uniqueness of room member events in the database confusing HAVING COUNT() test of room membership intersection (with thanks to Tom Molesworth)
2014-12-02 21:36:53 +00:00
Paul "LeoNerd" Evans
274d137b00
Extra verbosity on logging of received presence info
2014-12-02 20:51:28 +00:00
Paul "LeoNerd" Evans
307f94dcbe
Squash room_ids list to a set() to remove duplicates - with TODO marker as I have no idea /why/ the dups are happening in the first place
2014-12-02 20:51:12 +00:00
Mark Haines
2f804a7072
Fix pyflakes and pep8 warnings
2014-12-02 19:55:18 +00:00
Mark Haines
5da65085d1
Get uploads working with new media repo
2014-12-02 19:51:47 +00:00
Paul "LeoNerd" Evans
afb646dc1e
Allow GET /room/:room_id/messages without 'limit' parameter to default to 10
2014-12-02 18:01:16 +00:00
Erik Johnston
23a2c42469
Bump version
2014-12-02 17:45:40 +00:00
Mark Haines
7993e3d10d
SYN-187: Set a more sensible default for the content_addr
2014-12-02 17:20:02 +00:00
Mark Haines
279c48c8b4
Write the upload portion of version 1 of the media repository
2014-12-02 17:13:14 +00:00
Erik Johnston
c1e66800a9
Begin fleshing out a new Event object
2014-12-02 11:40:22 +00:00
Erik Johnston
9d53228158
Change DomainSpecificString so that it doesn't use a HomeServer object
2014-12-02 10:42:28 +00:00
Erik Johnston
ec2b5d8c28
Store full JSON of events in db
2014-12-01 16:22:07 +00:00
Erik Johnston
ab74afdd8d
Bump version
2014-11-27 17:30:08 +00:00
Erik Johnston
cce32f8dc5
Bump version and changelog
2014-11-27 17:15:32 +00:00
Erik Johnston
1505055334
Don't return outliers when we get recent events for rooms.
2014-11-27 16:38:50 +00:00
Erik Johnston
027542e2e5
Fix bugs when joining a remote room that has dodgy event graphs. This should also fix the number of times a HS will trigger a GET /event/
2014-11-27 16:02:26 +00:00
Erik Johnston
0294fba042
on_receive_pdu takes more args
2014-11-27 14:46:33 +00:00
Erik Johnston
07699b5871
Change the way we get missing auth and state events
2014-11-27 14:31:43 +00:00
Erik Johnston
b8849c8cbf
Re-sign events when we return them via federation as a temporary hack to work around the problem where we reconstruct events differently than when they were signed
2014-11-27 13:53:31 +00:00
Erik Johnston
00ab5cd6f2
Attempt to fix bug where we 500d an event stream due to trying to cancel a timer twice
2014-11-26 18:04:33 +00:00
Erik Johnston
858e87ab0d
Add a workaround for bug where some initial join events don't reference creation events in their auth_events
2014-11-26 16:29:03 +00:00
Erik Johnston
6c485c282d
Catch exceptions when trying to add an entry to rooms tables
2014-11-26 16:06:20 +00:00
Erik Johnston
5288a7dc9a
Bump version and changelog
2014-11-26 15:19:08 +00:00
Erik Johnston
4e2ffe79a4
Don't delete the entire current_state_events table
2014-11-26 15:17:08 +00:00
Erik Johnston
ad13f14432
Bump version numbers and change log
2014-11-26 11:53:12 +00:00
Erik Johnston
cb76945688
Add update delta for schema change
2014-11-26 11:17:19 +00:00
Erik Johnston
87538711b6
Update schema to support multiple signatures
2014-11-26 11:14:30 +00:00
Erik Johnston
3598c11c8d
Correctly handle the case where we get an event for an unknown room, which turns out we are actually in
2014-11-26 10:41:08 +00:00
Erik Johnston
64fc859dac
Fix bugs in invite/join dances.
...
We now do more implement more of the auth on the events so that we
don't reject valid events.
2014-11-25 17:59:49 +00:00
Kegan Dougal
3536fd7d60
Don't double url-decode state event types.
2014-11-25 11:02:19 +00:00
Mark Haines
15099fade5
Drop log level for incorrect logging contexts to WARN if the context is wrong and DEBUG if the context is missing
2014-11-25 10:57:31 +00:00
Erik Johnston
4961a4fab1
Mark the auth events as possible outlier
2014-11-24 13:55:49 +00:00
Erik Johnston
e549aac127
Add missing None check
2014-11-24 13:47:58 +00:00
Erik Johnston
2bca242fdc
Ask for any auth events that we don't have
2014-11-24 13:46:41 +00:00
Erik Johnston
4bd0ab76c6
We don't always want to Auth get_persisted_pdu
2014-11-24 12:56:17 +00:00
Erik Johnston
a46e5ef621
SYN-163: Add an order by rowid to selects.
...
This should fix the bug where the edges of the graph get returned in a
different order than they were inserted in, and so no get_event no
longer returned the exact same JSON as was inserted. This meant that
signature checks failed.
2014-11-24 10:56:36 +00:00
Matthew Hodgson
ae8ad55cb8
typos
2014-11-24 01:41:12 +00:00
Mark Haines
fd40a80a68
Return 404 M_NOT_FOUND when trying to look up a room alias that doesn't exist
2014-11-21 15:11:48 +00:00
Paul "LeoNerd" Evans
5f19c55731
SYN-58: Allow passing explicit limit=0 to initialSync to request no messages at all; missing still implies default 10
2014-11-20 19:33:45 +00:00
Mark Haines
610c2ea131
Fix pep8 and pyflakes warnings
2014-11-20 18:00:10 +00:00
David Baker
f1c7f8e813
Merge branch 'develop' into http_client_refactor
2014-11-20 17:49:48 +00:00
David Baker
e377d33652
Separate out the matrix http client completely because just about all of its code it now separate from the simple case we need for standard HTTP(S)
2014-11-20 17:41:56 +00:00
Mark Haines
db9ce032a4
Fix pep8 codestyle warnings
2014-11-20 17:26:36 +00:00
Mark Haines
dfdda2c871
Use module loggers rather than the root logger. Exceptions caused by bad clients shouldn't cause ERROR level logging. Fix sql logging to use 'repr' rather than 'str'
2014-11-20 17:10:37 +00:00
Mark Haines
32090aee16
Add a few missing yields, Move deferred lists inside PreserveLoggingContext because they don't interact well with the logging contexts
2014-11-20 16:24:00 +00:00
David Baker
20326054da
Oops, I removed this param.
2014-11-20 15:24:38 +00:00
David Baker
dc60eee50e
Refactor the HTTP clients a little.
2014-11-20 13:53:34 +00:00
David Baker
cf66532ac1
CaptchaServerHttpClient should extend the base, not matrix http client.
2014-11-20 12:48:21 +00:00
Mark Haines
b2aeaa2dcc
Merge branch 'master' into develop
2014-11-20 10:00:13 +00:00
Mark Haines
dcb99e4972
SYN-153: Fix formatting of federation error message
2014-11-20 09:58:23 +00:00
Erik Johnston
1a9551db82
Merge branch 'develop' of github.com:matrix-org/synapse into release-v0.5.0
2014-11-19 18:03:03 +00:00
Erik Johnston
5b46ce579b
Bump version, changelog and upgrade.rst
2014-11-19 18:00:57 +00:00
Erik Johnston
415ddf59bb
Don't add a 'prev' key to m.room.member messages
2014-11-19 17:59:51 +00:00
Paul "LeoNerd" Evans
03dc63f6c8
Initialise UserPresenceCache instances to always contain a 'presence' key
2014-11-19 17:31:46 +00:00
Erik Johnston
4eada9a908
Fix backfill request
2014-11-19 17:22:37 +00:00
Erik Johnston
512993b57f
Only users can set state events which have their own user_id
2014-11-19 17:22:37 +00:00
Mark Haines
ca91bb2f7f
Sometimes there isn't a current logging context
2014-11-19 17:18:55 +00:00
Mark Haines
8993affdc0
SYN-153: Raise 404 if room alias is not found
2014-11-19 17:14:14 +00:00
Mark Haines
0d1221155e
remove unused import
2014-11-19 16:40:01 +00:00
Mark Haines
c5eabe3143
replace user_id with sender
2014-11-19 16:38:40 +00:00
Mark Haines
97c7c34f6f
Preserve logging context in a few more places, drop the logging context after it has been stashed to reduce potential for confusion
2014-11-19 16:37:43 +00:00
Mark Haines
3e54d70ae2
SYN-141: Encode query params as UTF-8.
2014-11-18 19:43:08 +00:00
Mark Haines
428581dd05
SYN-144: Remove bad keys from pdu json objects, convert age_ts to age
...
for all pdus sent.
2014-11-18 19:20:25 +00:00
Paul "LeoNerd" Evans
572a1ca42a
Remember also to UTF-8 decode bytes in room alias names in directory server URLs
2014-11-18 18:06:35 +00:00
Paul "LeoNerd" Evans
3bfc3dd45b
Remember to URL decode the room_id in room initialSync
2014-11-18 17:44:55 +00:00
Mark Haines
db7e8b5619
SYN-141: Decode the query params as UTF-8
2014-11-18 17:17:57 +00:00
Mark Haines
54c438d8d3
Remove unused variable
2014-11-18 16:46:12 +00:00
Mark Haines
1731af3f29
SYN-104: When going backwards the end token should be before the last event
2014-11-18 16:45:06 +00:00
Paul Evans
11fd81e398
Merge pull request #17 from matrix-org/room-initial-sync
...
Room initial sync
2014-11-18 16:44:25 +00:00
Paul "LeoNerd" Evans
88dfa7baa6
Ensure to parse a real pagination config object out of room initialSync request and pass it on
2014-11-18 16:34:43 +00:00
Paul "LeoNerd" Evans
75e95c45a2
Rename message handler's new snapshot_room to room_initial_sync() as that better suits its purpose
2014-11-18 16:02:44 +00:00
Erik Johnston
c6ea29d916
Revert accidental commit of bad file
2014-11-18 15:57:00 +00:00
Paul "LeoNerd" Evans
e9f587ecba
Merge remote-tracking branch 'origin/develop' into room-initial-sync
2014-11-18 15:48:30 +00:00
Mark Haines
3553101eb3
Null check when determining default power levels
2014-11-18 15:43:17 +00:00
Mark Haines
b01dd76be1
SYN-149: Enable auth for events added during room creation since they should pass auth checks
2014-11-18 15:42:53 +00:00
Erik Johnston
95614e5220
Fix auth to correctly handle initial creation of rooms
2014-11-18 15:36:41 +00:00
Mark Haines
ae9c2ab165
SYN-149: Send join event immediately after the room create event
2014-11-18 15:29:48 +00:00
Paul "LeoNerd" Evans
33d328d967
Include room members' presence in room initialSync
2014-11-18 15:28:58 +00:00
Paul "LeoNerd" Evans
759db7d7d5
Added ability to .get_state() from the PresenceHandler by returning a complete m.presence event
2014-11-18 15:25:55 +00:00
Paul "LeoNerd" Evans
4c18e08036
Don't expect all _user_cachemap entries to definitely contain a "last_active" key
2014-11-18 15:10:11 +00:00
Mark Haines
a5b88c489e
Split out sending the room alias events from creating the alias so that we can do them in the right point when creating a room
2014-11-18 15:03:13 +00:00
Paul "LeoNerd" Evans
17f977a9de
Include 'messages' snapshot in room initialSync
2014-11-18 14:07:51 +00:00
Mark Haines
26fc878944
Stop before starting when restarting
2014-11-17 19:16:15 +00:00
Paul "LeoNerd" Evans
31a049eb69
Merge branch 'develop' into room-initial-sync
...
Conflicts:
synapse/handlers/message.py
2014-11-17 16:59:24 +00:00
Mark Haines
cf45e57d9c
SYN-148: Add the alias after creating the room
2014-11-17 16:37:33 +00:00
Mark Haines
2eaf689f71
These lines aren't doing anything
2014-11-17 10:41:35 +00:00
Mark Haines
cb4b6c844a
Merge PDUs and Events into one object
2014-11-14 21:25:02 +00:00
Mark Haines
8c2b5ea7c4
Fix PDU and event signatures
2014-11-14 19:11:04 +00:00
Mark Haines
de1ec90133
Validate signatures on incoming events
2014-11-14 19:11:04 +00:00
David Baker
fe3401e037
Be more helpful and tell the user how to generate a config too.
2014-11-14 13:30:06 +00:00
David Baker
933ce76057
Adding --generate-config will not help if the user has not specified a config file.
2014-11-14 13:24:12 +00:00
Mark Haines
e903c941cb
Merge branch 'develop' into request_logging
...
Conflicts:
setup.py
synapse/storage/_base.py
synapse/util/async.py
2014-11-14 11:16:50 +00:00