Commit graph

3384 commits

Author SHA1 Message Date
jesopo
7a860240ef set content_type=ACTIVITY_TYPE on outbox 2019-09-10 18:48:26 +01:00
jesopo
ed07149257 remove unused duplicate ACTIVITY_TYPE 2019-09-10 18:48:15 +01:00
jesopo
be6f875e25 Revert "call self.finish() in rest_api.py in hopes it will force-close connections"
This reverts commit 5d6b2ff083.
2019-09-10 18:33:14 +01:00
jesopo
5d6b2ff083 call self.finish() in rest_api.py in hopes it will force-close connections 2019-09-10 18:28:50 +01:00
jesopo
1dfb3c4461 '_prepare_actitivy' -> '_prepare_activity' 2019-09-10 18:21:20 +01:00
jesopo
02b038e15f get_activities is a list, not a dict 2019-09-10 18:20:22 +01:00
jesopo
8726bd9717 implement first draft of fediverse outbox 2019-09-10 18:08:58 +01:00
jesopo
74d2c18954 return error codes from webfinger 2019-09-10 17:34:01 +01:00
jesopo
a99f359266 fix setting exported from fediverse_server.py 2019-09-10 17:33:49 +01:00
jesopo
c697c3bbb2 split out fediverse server to it's own module 2019-09-10 17:32:41 +01:00
jesopo
e96783dfac support webfinger resource not having "acct:" on the front 2019-09-10 16:51:08 +01:00
jesopo
e048f61c73 .strip() client cert to remove needless newlines 2019-09-10 16:42:09 +01:00
jesopo
d75d33c42c "%s", not "%d", cuz port is a str 2019-09-10 16:41:16 +01:00
jesopo
a02bfdf157 get REST API port from settings if it's not in Host header 2019-09-10 16:39:44 +01:00
jesopo
d2de2cca7d 'index' -> 'inbox' 2019-09-10 16:30:54 +01:00
jesopo
7636843fc7 'get_params' -> 'get_params_str' 2019-09-10 16:29:35 +01:00
jesopo
b6f4e9c458 'location' -> 'self_id' 2019-09-10 16:24:11 +01:00
jesopo
eb5b0c25b6 'for_url' -> 'url_for', '_ap_self._id' -> '_ap_self_id' 2019-09-10 16:22:54 +01:00
jesopo
7dac75e566 implement ActivityPub user endpoint 2019-09-10 16:21:31 +01:00
jesopo
49527495b8 CaseInsensitiveDict does not implement .get() yet 2019-09-10 15:59:54 +01:00
jesopo
6b17c64b15 'resouce' -> 'resource' 2019-09-10 15:51:58 +01:00
jesopo
3993447eeb 'account' is no longer reformatted u@instance 2019-09-10 15:46:25 +01:00
jesopo
90d0452bfd first draft of ActivityPub webfinger 2019-09-10 15:40:01 +01:00
jesopo
8d8d9219b8 don't return "+" when a channel has no modes 2019-09-10 15:10:14 +01:00
jesopo
ef7da3409b don't bother sorting json keys when the json is minified 2019-09-10 15:08:06 +01:00
jesopo
9ac46bab7d duplicate 'rest-api' setting - copypaste issue for rest-api-minify 2019-09-10 15:00:47 +01:00
jesopo
2fc75c6af7 move more REST API code on to the main thread 2019-09-10 13:55:06 +01:00
jesopo
8653068650 'code' -> 'response.code' 2019-09-10 13:45:55 +01:00
jesopo
4a08c2d134 set response.code=200 as soon as we know there's a hook waiting for it 2019-09-10 13:45:14 +01:00
jesopo
fefb9d71fb 'event_response' -> 'obj' (copypaste error) 2019-09-10 13:39:59 +01:00
jesopo
3a0183eb03 refactor REST API to use a Response object 2019-09-10 13:38:25 +01:00
jesopo
7fbb5b2823 don't use full event names to check what command we're in 2019-09-10 12:59:52 +01:00
jesopo
bad108d7ce support disabling word tracking per channel, not just per user 2019-09-10 10:34:44 +01:00
jesopo
a9d11fc7f8 use rpartition, not partition, to avoid splitting on leading @ 2019-09-09 21:35:54 +01:00
jesopo
6d176a6aa1 add !unsilence 2019-09-09 18:06:37 +01:00
jesopo
0c5171a44f add +time param to !silence 2019-09-09 18:06:27 +01:00
jesopo
695c7982a6 add a special flag to allow commands to bypass !silence 2019-09-09 18:05:10 +01:00
jesopo
a9b106c6be Don't try to .decode non-html things, default iso-lat-1 for non-html too 2019-09-09 16:17:26 +01:00
jesopo
c8ece388cc use detect_encoding=False in github webhook url shortening 2019-09-09 16:08:51 +01:00
jesopo
b83f5d9e30 add flag to disable encoding detection 2019-09-09 14:59:08 +01:00
jesopo
5ef2b7af27 'str.split' -> 's.split' 2019-09-09 14:53:11 +01:00
jesopo
1df82c1cb2 still default to iso-latin-1 if no on-page or in-header content-type is present 2019-09-09 14:48:26 +01:00
jesopo
0a67659637 only look for <meta>-related tags when there are meta tags 2019-09-09 14:39:19 +01:00
jesopo
8e824c9277 add !8 as alias of !8ball 2019-09-09 14:25:19 +01:00
jesopo
0a1077c5cd add explicit None return for _find_encoding (mypy) 2019-09-09 14:25:01 +01:00
jesopo
ff9c82bf67 change utils.http.request to best-effort detect on-page encoding
closes #113
2019-09-09 14:11:18 +01:00
jesopo
98931de283 remove redundant (and maybe wrong) GET params from webfinger call
closes #143
2019-09-09 10:30:06 +01:00
jesopo
b1033a0721 support location names for !timezone too 2019-09-08 18:22:04 +01:00
jesopo
95c007c1da support showing time for locations, not just users 2019-09-08 18:17:32 +01:00
jesopo
896b98bbd1 remove LOW priority from youtube regex - it doesnt need it 2019-09-08 12:21:28 +01:00