Wykres commitów

180 Commity (f933c7e2370662a9a1a61970d8f4536558bb0ab1)

Autor SHA1 Wiadomość Data
Ryan Barrett f933c7e237
AP users: serve AS2 for external homepage URLs
#512
2023-05-22 23:17:42 -07:00
Ryan Barrett a14aa7367a
wm => AP, error on follow without target
fixes https://console.cloud.google.com/errors/detail/CIDY9567zMDQrwE;time=P30D?project=bridgy-federated
2023-05-17 14:52:39 -07:00
Ryan Barrett 2758acc6cb
wm => AP bug fix: if source has multiple u-follow-ofs, store individual last_follows
fixes https://console.cloud.google.com/errors/detail/COGA_MbTzeDJqgE;time=P30D?project=bridgy-federated
2023-04-23 21:13:11 -07:00
Ryan Barrett 5aba64004f
wm => AP: inline most objects as bare string ids, not composite objects
for interop
2023-04-19 16:21:21 -07:00
Ryan Barrett d2ab48b23e
switch circular imports to runtime imports; split out flask_app.py from app.py
runtime imports are just as bad, but...meh. eventually I'll untangle them for real. #486
2023-04-18 17:18:17 -07:00
Ryan Barrett 6066c87f73
wm => AP: deliver reposts to all followers
fixes #476
2023-04-17 19:20:22 -07:00
Ryan Barrett 212f2b11ec
wm => AP: add delete support
fixes #30
2023-04-17 15:36:29 -07:00
Ryan Barrett 92ec40007b
webmention.py noop: move webmention_interactive() up under webmention_external() 2023-04-17 07:51:26 -07:00
Ryan Barrett 65b8469f2a
/webmention : add back logging message for monitoring 2023-04-09 14:34:22 -07:00
Ryan Barrett ac0dc216ce
convert wm => AP to all async, enqueue task for every incoming webmention
fixes bug where we were fetching and storing an Object for an incoming wm, enqueueing a task, then in the task we'd refetch, see that it was unchanged, and do nothing.

thanks @jamietanna @gregorlove for reporting!
2023-04-06 09:19:05 -07:00
Ryan Barrett 22ca59749e
stop using common.actor() in User.verify() 2023-04-04 22:06:13 -07:00
Ryan Barrett 1f40aedf27
webmention.py: unify homepage update logic, move fetching into fetch() 2023-04-04 18:02:41 -07:00
Ryan Barrett 816a635738
bug fix for update profile button on user page UI
fixes https://console.cloud.google.com/errors/detail/CMK10__x4ZbgbQ;time=P30D?project=bridgy-federated
2023-04-04 07:24:06 -07:00
Ryan Barrett 629c1a2bd4
unify Object.new/changed generation into Protocol.load
also:
* switch back to preserving fragments in URL ids
* webmention.fetch: if URL id redirects, preserve original id in Object
2023-04-03 07:53:15 -07:00
Ryan Barrett f836762b0f
big webmention.py refactoring
* use Objects properly
* use Object's mf2/AS2/AS1 conversion
* drop resuming partially completed deliveries
* use load, fetch, send
* get closer to unifying all activity handling into Protocol.receive
2023-04-01 19:13:51 -07:00
Ryan Barrett e41ce9216c
noop, rename Protocol.get_object => Protocol.load 2023-03-29 13:13:32 -07:00
Ryan Barrett c3192cc1df
Webmention.fetch: add full authorship algorithm and fetch 2023-03-26 16:47:46 -07:00
Ryan Barrett 28e8baff6c
change Protocol.fetch() to return an Object instead of populating one 2023-03-22 20:49:28 -07:00
Ryan Barrett 20f86c7de3
handle wm => AP with targets that we've already federated wm => AP
fixes https://console.cloud.google.com/errors/detail/CMHpr9L3ooGKeQ;time=P30D?project=bridgy-federated
2023-03-22 12:30:55 -07:00
Ryan Barrett acf474e2a9
standardize fetch(id, obj) args 2023-03-20 19:25:05 -07:00
Ryan Barrett fb5f7b3fb0
move current user into Flask g request-global 2023-03-20 14:28:14 -07:00
Ryan Barrett b2c60226b7
add Webmention.send, tweak method signature 2023-03-20 11:26:43 -07:00
Ryan Barrett 7dc5a060a6
start Webmention subclass of Protocol, implement fetch 2023-03-19 21:08:24 -07:00
Ryan Barrett d433dd3abe
wm => AP: switch actors in outgoing activities from objects to string ids
mostly. also inlines single-element attributedTo lists to just the element, without the list.
2023-03-19 09:34:42 -07:00
Ryan Barrett 5169c2e44e
misc noop tweaks, mostly tests 2023-03-19 09:34:42 -07:00
Ryan Barrett 5e3c623552
add User.actor_id() 2023-03-19 09:34:42 -07:00
Ryan Barrett 31645618dc
abstracting protocols: start to use send()
#388
2023-03-10 07:36:50 -08:00
Ryan Barrett ffd8810b44
start to separate logic from protocols with new Protocol/ActivityPub classes
for #388
2023-03-10 07:36:50 -08:00
Ryan Barrett 2dfddec2ef
convert activitypub.py logic to use all AS1 2023-03-03 09:28:40 -08:00
Ryan Barrett 150f2ec5fe
webmention.py: noop refactoring, drop self.source_domain 2023-02-25 21:41:57 -06:00
Ryan Barrett 42c648284d
noop TODO comment 2023-02-24 11:51:24 -06:00
Ryan Barrett fd27dabe61
switch JSON properties to custom JSONProperty that works in web console UI
https://github.com/googleapis/python-ndb/issues/874#issuecomment-1442753255
2023-02-24 07:25:29 -06:00
Ryan Barrett 91a60c7e67
switch Object.as1 to be a ComputedProperty 2023-02-23 21:17:26 -06:00
Ryan Barrett e423bde6d0
unify logging for writing datastore entities into post put hook
and other logging tweaks
2023-02-14 15:38:42 -08:00
Ryan Barrett 588598c5ff
switch most uses of common.get_as2 to common.get_object 2023-02-14 14:56:27 -08:00
Ryan Barrett d64e5e875e
test_webmention: drop unused atom test data 2023-02-14 07:40:37 -08:00
Ryan Barrett 6446c8c421
convert Object.type and .object_ids to ComputedPropertys
https://googleapis.dev/python/python-ndb/latest/model.html#google.cloud.ndb.model.ComputedProperty
2023-02-13 21:43:49 -08:00
Ryan Barrett f39c532ad3
add User.homepage, is_homepage() 2023-02-12 12:03:27 -08:00
Ryan Barrett ad63e23aeb
/webmention: check that user exists at the beginning, not the end 2023-02-10 10:53:39 -08:00
Ryan Barrett b739bd4cee
return 404 on requests for unknown users instead of automatically creating them 2023-02-07 18:28:52 -08:00
Ryan Barrett b5a0386cd0
store home page URL in update profile Objects, render better in activities UI
fixes #407
2023-02-07 12:44:41 -08:00
Ryan Barrett 52c6aa6160
fix update profile Object id
use synthetic URL with #update-[timestamp] fragment, not just home page URL
2023-02-07 12:23:08 -08:00
Ryan Barrett e1856c21a1
add more logging for when we write Objects 2023-02-07 08:24:36 -08:00
Ryan Barrett 4b37674624
always sign requests with current user's key, stop defaulting to snarfed.org
for #403
2023-02-06 19:23:25 -08:00
Ryan Barrett 08265123f6
Activity => Object: use 'in progress' status
#286
2023-02-04 20:46:28 -08:00
Ryan Barrett 532ccb8ac1
Activity => Object: use StructuredProperty for Object.delivered etc, add protocol
#286

ndb implements StructuredProperty by hoisting each nested property into a
corresponding property on the parent entity, prefixed by the StructuredProperty's
name, eg delivered.uri, delivered.protocol, etc.

For repeated StructuredPropertys, the hoisted properties are all repeated on the
parent entity, and reconstructed into StructuredPropertys based on their order.

https://googleapis.dev/python/python-ndb/latest/model.html#google.cloud.ndb.model.StructuredProperty
2023-02-04 20:46:27 -08:00
Ryan Barrett f9891b6ef7
Activity => Object: add activity label, unify Objects for AP => wm
#286
2023-02-04 20:46:27 -08:00
Ryan Barrett 4d2fcdd76f
Activity => Object: fully populate labels, source_protocol webmention
#286
2023-02-04 20:46:27 -08:00
Ryan Barrett a76fe45891
Activity => Object: finish ap_delivered, ap_undelivered, ap_failed
#286
2023-02-04 20:46:27 -08:00
Ryan Barrett 97ffc10f72
Activity => Object: populate Object.object_ids property
#286
2023-02-04 20:46:27 -08:00