summary refs log tree commit diff
path: root/synapse/events/__init__.py (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Add helpers for getting prev and auth events (#4139)Erik Johnston2018-11-061-0/+18
| | | | | | | * Add helpers for getting prev and auth events This is in preparation for allowing the event format to change between room versions.
* Disable frozen dicts by default (#3987)Amber Brown2018-10-021-3/+10
|
* Fix handling of redacted events from federationErik Johnston2018-09-131-0/+5
| | | | | | | | | | If we receive an event that doesn't pass their content hash check (e.g. due to already being redacted) then we hit a bug which causes an exception to be raised, which then promplty stops the event (and request) from being processed. This effects all sorts of federation APIs, including joining rooms with a redacted state event.
* run isortAmber Brown2018-07-091-2/+1
|
* Consistently use six's iteritems and wrap lazy keys/values in list() if ↵Amber Brown2018-05-311-1/+1
| | | | they're not meant to be lazy (#3307)
* add comment explaining attributeerrorAdrian Tschira2018-04-301-0/+3
|
* Make event properties raise AttributeError insteadAdrian Tschira2018-04-151-3/+12
| | | | | | | | | | | | | They raised KeyError before. I'm changing this because the code uses hasattr() to check for the presence of a key. This worked accidentally before, because hasattr() silences all exceptions in python 2. However, in python3, this isn't the case anymore. I had a look around to see if anything depended on this raising a KeyError and I couldn't find anything. Of course, I could have simply missed it. Signed-off-by: Adrian Tschira <nota@notafile.com>
* Optimise state resolutionErik Johnston2017-01-171-3/+5
|
* gah, fix mangled merge of 0.18.7 into developMatthew Hodgson2017-01-071-1/+1
|
* Only send events that originate on this server.Mark Haines2017-01-051-0/+9
| | | | | | Or events that are sent via the federation "send_join" API. This should match the behaviour from before v0.18.5 and #1635 landed.
* Make None optionalErik Johnston2016-08-261-1/+1
|
* Remove the is_new_state argument to persist event.Mark Haines2016-03-311-0/+3
| | | | | | | | | Move the checks for whether an event is new state inside persist event itself. This was harder than expected because there wasn't enough information passed to persist event to correctly handle invites from remote servers for new rooms.
* Use a stream id generator to assign state group idsMark Haines2016-03-301-1/+1
|
* Intern all the thingsErik Johnston2016-03-231-9/+2
|
* Intern sender, event_id and room_id in eventsErik Johnston2016-03-231-0/+5
|
* Intern type and state_key on eventsErik Johnston2016-03-231-0/+7
|
* Don't assume existence of event_id in __str__Erik Johnston2016-03-181-1/+3
|
* Make Event objects behave more like dictsErik Johnston2016-01-181-0/+9
|
* copyrightsMatthew Hodgson2016-01-071-1/+1
|
* Fix bug where we didn't correctly serialize the redacted_because key over ↵Erik Johnston2015-08-211-1/+4
| | | | federation
* Don't copy twiceErik Johnston2015-05-291-1/+1
|
* Add config option to turn off freezing events. Use new encode_json api and ↵Erik Johnston2015-05-291-1/+10
| | | | ujson.loads
* Store the rejected reason in (Frozen)Event structsPaul "LeoNerd" Evans2015-03-251-2/+4
|
* pyflakesErik Johnston2015-02-111-1/+1
|
* Don't unfreeze when using FreezeEvent.get_dict, as we are using a ↵Erik Johnston2015-02-111-4/+0
| | | | JSONEncoder that understands FrozenDict
* Rearrange persist_event so that do all the queries that need to be done ↵Erik Johnston2015-02-041-1/+1
| | | | before returning early if we have already persisted that event.
* Fix bug where we changes in outlier in metadata dict propogated to other eventsErik Johnston2015-01-301-1/+1
|
* Remove unused importErik Johnston2015-01-071-2/+0
|
* Optimize FrozenEvent creationErik Johnston2015-01-061-7/+13
|
* Update copyright noticesMark Haines2015-01-061-1/+1
|
* clean up coding style a bitMark Haines2014-12-161-11/+11
|
* Persist internal_metadataErik Johnston2014-12-161-2/+3
|
* Fix pyflakesErik Johnston2014-12-151-2/+0
|
* Use frozenutilsErik Johnston2014-12-151-32/+4
|
* Finish up upgrade scriptErik Johnston2014-12-151-1/+1
|
* Fix redactions. Fix 'age' keyErik Johnston2014-12-111-0/+1
|
* Actually fix bug when uploading state with empty state_keyErik Johnston2014-12-101-0/+1
|
* Fix bug when uploading state with empty state_keyErik Johnston2014-12-101-2/+8
|
* Fix AttributeErrorErik Johnston2014-12-101-0/+3
|
* Add __str__ to FrozenEventErik Johnston2014-12-101-0/+5
|
* Try and figure out how and why signatures are being changed.Erik Johnston2014-12-101-8/+10
|
* More bug fixesErik Johnston2014-12-081-8/+1
|
* Start making more things use EventContext rather than event.*Erik Johnston2014-12-051-2/+33
|
* Convert rest and handlers to use new event structureErik Johnston2014-12-041-4/+4
|
* Begin converting things to use the new Event structureErik Johnston2014-12-041-0/+3
|
* WIP for new way of managing events.Erik Johnston2014-12-031-64/+77
|
* Begin fleshing out a new Event objectErik Johnston2014-12-021-0/+120