Ryan Barrett
f997477366
User.get_or_create: move profile object load out of datastore transaction
...
hoping to cut down https://console.cloud.google.com/errors/detail/CKbL5KSX98uZHw;time=P1D;locations=global?project=bridgy-federated a bit
2024-09-12 13:05:41 -07:00
Ryan Barrett
36a9f94cb8
add fallback kwargs to User.user_link, Protocol.bridged_web_url_for
...
for #966
2024-09-10 16:44:18 -07:00
Ryan Barrett
16a9a5b29e
add rel=me to user page links
...
for #1309
2024-09-09 08:29:19 -07:00
Ryan Barrett
150598d761
User.user_link: refactor to get rid of extra spaces
2024-08-25 09:48:32 -07:00
Ryan Barrett
6675d9805c
User.user_link: add name, handle, pictures, proto kwargs, remove maybe_internal_link
2024-08-21 07:55:09 -07:00
Ryan Barrett
9467bccb5e
noop: User.count_followers optimization, do queries async
2024-08-21 07:55:09 -07:00
Ryan Barrett
2ed8ba2d0f
DM to request bridging: send acknowledgment DM to requester
...
for #966
2024-08-19 21:48:02 -07:00
Ryan Barrett
e96c61559e
tests bug fix: ExplicitEnableFake needs explicit enabling *both* directions
2024-08-19 20:08:03 -07:00
Ryan Barrett
004d3617f8
dms.receive: first pass at DM handle to request bridging
...
for #966
2024-08-19 13:26:45 -07:00
Ryan Barrett
ecab888a02
move incoming DM handling from Protocol.receive to dms.receive
2024-08-18 08:29:05 -07:00
Ryan Barrett
be2b36cf8a
start new dms module, move Protocol.maybe_bot_dm into it
2024-08-17 22:53:14 -07:00
Ryan Barrett
0ce8eaff1a
Protocol.bot_dm => maybe_bot_dm, populate and check User.sent_dms
...
for #1205 , #1148 , #966 , #1024
2024-08-15 17:24:25 -07:00
Ryan Barrett
17371a31cb
switch User.sent_dms from Target to new DM type
2024-08-15 14:35:49 -07:00
Ryan Barrett
eedc77fcb8
make User.sent_dms per-protocol by changing its type to Target
...
for #1205 , #1148 , #966 , #1024
2024-08-14 15:11:56 -07:00
Ryan Barrett
eb9b28faa8
add User.sent_dms to track the DMs we've sent to a user
...
for #1205 , #1148 , #966 , #1024
2024-08-14 14:10:21 -07:00
Ryan Barrett
07b8a3de1d
User.enable_protocol: fill in real welcome DM message
...
for #1024 , #966 , etc
2024-08-08 22:21:40 -07:00
Ryan Barrett
23aa24eb4f
User.enable_protocol: send welcome DM
...
via new Protocol.bot_dm method
for #1024 , #966 , etc
2024-08-08 20:17:06 -07:00
Ryan Barrett
0f14410cf2
User.get_or_create: consolidate puts better
...
c47f364
caused lots of contention, this hopefully fixes that. https://console.cloud.google.com/errors/detail/CJm_4sDv9O-iKg;time=P1D;locations=global?project=bridgy-federated
2024-08-06 11:57:18 -07:00
Ryan Barrett
479acea657
move Web.verify from /web-site handler to Web.get_or_create
...
for #1232
2024-08-06 11:07:13 -07:00
Ryan Barrett
c47f3640e6
User.get_or_create: cut down extra puts
2024-08-05 13:48:44 -07:00
Ryan Barrett
70dd6d3ceb
minor logging optimizations
...
for https://github.com/snarfed/bridgy-fed/issues/1149
2024-08-02 08:03:44 -07:00
Ryan Barrett
5679d696a4
cache models.get_originals in memory
...
for #1149
2024-08-01 16:20:13 -07:00
Ryan Barrett
3529216e5d
disable caching get_originals ( 88cbe3b
) until bugs are fixed
...
for #1149
2024-07-31 09:14:31 -07:00
Ryan Barrett
88cbe3b7b4
cache models.get_originals in memcache with new memcache_memoize decorator
...
for #1149
2024-07-30 14:50:33 -07:00
Ryan Barrett
100a208e5e
add allow_opt_out to Protocol.key_for, User.get_or_create, Protocol.receive internal
...
for #1204
2024-07-23 19:26:30 -07:00
Ryan Barrett
f34d1b43a3
User.status: make opt in override #nobot but not #nobridge
...
for #1204 , re #974
2024-07-23 13:54:24 -07:00
Ryan Barrett
f1713e68d9
drop a bunch of log messages from info to debug
...
...and other logging tweaks
for https://github.com/snarfed/bridgy-fed/issues/1060
2024-07-18 14:15:12 -07:00
Ryan Barrett
746c57a931
/convert: handle Bluesky objects that we can't (yet) convert to AS1
...
fixes https://console.cloud.google.com/errors/detail/CICesouJo-PV7AE;time=P30D?project=bridgy-federated
2024-07-18 09:56:54 -07:00
Ryan Barrett
0a22643cef
User.get_or_create: merge enabled_protocols
...
for #1034
2024-07-15 20:09:20 -07:00
Ryan Barrett
ee62334a93
turn on web <=> Bluesky!
...
for #1034
2024-07-15 19:40:10 -07:00
Ryan Barrett
8307b38024
noop: User.get_by_id: add missing **kwargs
2024-07-10 12:30:14 -07:00
Ryan Barrett
714c317dd4
Protocol.targets: only deliver reposts, replies etc if the original post was bridged
...
for #1166 , #1151 , maybe others. #1151 is the big motivation here: that we're currently generating and sending Bluesky a ton of reposts with blank subject cid/URL, which afaict is the main reason bridging is getting stuck for some accounts and the relay is constantly calling `getRepo`. I'm hoping this will reduce or eliminate that.
this isn't a big behavior change, but it is a kind of big change to routing logic. it's tested pretty well, but I still expect something to break. we'll see.
2024-07-09 17:29:02 -07:00
Ryan Barrett
8457f2a048
drop unused Object.object_ids computed property
2024-06-27 13:20:07 -07:00
Ryan Barrett
16724974b7
User.get_or_create bug fix: check status when creating a new user
2024-06-23 09:08:13 -07:00
Ryan Barrett
349f4ba544
user page UI: ellipsize user-visible handles
...
fixes #994
2024-06-19 11:05:10 -07:00
Ryan Barrett
cb2a3bef0b
Object: drop legacy converting (un-escaping) between ^^ and # in ids/URLs
...
for #469 , well over a year old, I think we're safe to forget about this now
2024-06-13 13:24:32 -07:00
Ryan Barrett
fdca3b6d55
Protocol.receive: don't attempt to deliver to followers on non-enabled protocols
...
mostly just handles this more gracefully. these deliveries were failing anyway, just not cleanly. fixes eg https://console.cloud.google.com/errors/detail/CMHloZaRmPXQZQ;time=P30D?project=bridgy-federated , probably others too
2024-06-13 12:02:54 -07:00
Ryan Barrett
026d99edc0
pass ignore_links=True to html_to_text everywhere
...
for #976
2024-06-06 18:14:35 -07:00
Ryan Barrett
3fe402e54c
drop Object cache in Protocol.load
2024-06-04 14:27:04 -07:00
Ryan Barrett
712da61181
auth error reporting: standardize messages, include HTTP context
...
trying to collect them into two top-level Error Reporting errors, with details for each one in the user field
for #566
2024-06-04 11:27:17 -07:00
Ryan Barrett
bad49575fb
Web: always use fetched URL as id, not u-url
...
fixes #829 , cc #566
2024-06-03 16:20:46 -07:00
Ryan Barrett
cc564a2b19
turn on authorization checks! HTTP sig matches actor, actor is allowed to modify object
...
for #566
2024-06-03 14:12:08 -07:00
Ryan Barrett
251bd202d7
deprecate Users.atproto_notifs_indexed_at, atproto_feed_indexed_at
2024-06-03 14:12:08 -07:00
Ryan Barrett
a2376f8f14
prune more logging messages
2024-06-01 07:17:44 -07:00
Ryan Barrett
fabfb58aa4
Object.get_or_create authz: allow an id on its own object
...
for #566
2024-05-29 20:17:33 -07:00
Ryan Barrett
d6728a2e1b
Object.get_or_create authz check: allow a user to modify their profile object
...
for #566
2024-05-29 16:39:09 -07:00
Ryan Barrett
8f5d8221a9
add ids.profile_id, use everywhere
...
for #566
2024-05-29 16:18:15 -07:00
Ryan Barrett
bfbae4b280
authz: normalize user ids before comparing, in both receive and Object.get_or_create
...
for #566
2024-05-29 12:29:38 -07:00
Ryan Barrett
f2a64c8b5c
Object.get_or_create: rename actor => authed_as, add to all calls
...
for #566
2024-05-28 16:07:32 -07:00
Ryan Barrett
0a3976e33a
Object._post_put_hook: use objects_cache_lock for objects_cache
...
fixes https://console.cloud.google.com/errors/detail/CMv025380KiFOg?project=bridgy-federated
2024-05-27 20:38:51 -07:00