* apply block rules for third parties on replies and embeds
* tidy terminology around blocking and actor relationships
* apply third-party blocking functionality to appview
* tidy, bsky tests
* refactor appview services
* tidy types
* Allow moderators to take and reverse actor takedowns (#1330)
allow moderators to take and reverse actor takedowns
* ✨ Allow searching reports by moderator did (#1283)
* ✨ Allow searching reports by moderator did
* ✅ Remove .only flags on tests
* ✅ Update snapshot
* ✅ Add checks for did match in actions
* v0.4.1
* Make sequencer leader behavior optional on pds (#1250)
* make sequencer leader behavior optional on pds
* tidy
* use 127.0.0.1 in with-test-db.sh for colima (#1297)
So, since Docker Desktop has licensing issues, some folks use colima for
running containers on their macOS machines (The licensing exempted
CLI-only version of Docker only exists on Linux).
Unfortunately, colima binds host ports only on the IPv4 localhost
address (`127.0.0.1`) while the atproto postgres clients will attempt to
connect to the IPv6 localhost address (`::1`) that macOS sets in
/etc/hosts. See https://github.com/abiosoft/colima/issues/583 and
https://github.com/lima-vm/lima/issues/1330 for the tickets against
colima. (Docker Desktop binds to both IPv4 and IPv6 localhost addresses
and so doesn't have this issue.)
To workaround this silly issue, we can use `localhost` within the docker
containers and docker-compose, but need to set the `DB_POSTGRES_URL` env
var to use the IPv4 localhost explicitly.
(Asking folks to edit /etc/hosts causes other tools to break and will be
overridden on each OS upgrade.)
* Subscription util tests (#1295)
* consecutive list tests
* flesh out subscription util tests
---------
Co-authored-by: Devin Ivy <devinivy@gmail.com>
* Content reporting on record fields (#1351)
* content reporting on record fields
* fix test
* tests
* tidy
* Check rkey contents just for non-tids (#1353)
check rkey content for non-tids
* ✨ Added new procedure for sending admin email (#1312)
* 🚧 Added new lexicon for sending admin email
* ✨ Add moderation mailer
* ✨ Switch to text email content from html
* 🧹 Cleanup some early implementation code and reflect PR reivew
* ✨ Use smtp host instead of gmail service config
* ✨ Move to using single smtp url
* v0.4.2
* Patch up a couple sqlite tests (#1355)
patch up a couple sqlite tests
* Increase appview keepalive (#1360)
increase keepalive to 90s
* Appview - serve feed skeletons (#1265)
* proxy timeline skeleton construction to appview
* add getFeedSkeleton to appview
* mount route
* smart proxy feed skeletons
* tests
* proper error code
* only proxy specific feeds
* build branch
* update proxyable feed logic, should use feed publisher rather than generator
* fix feed proxy tests, configure feed publisher (in addition to generator)
* hotfix: prevent user-supplied rkey on posts with createRecord (#1313)
* prevent user-supplied rkey on posts with createRecord
* allow empty-string rkey parameter
Co-authored-by: devin ivy <devinivy@gmail.com>
---------
Co-authored-by: devin ivy <devinivy@gmail.com>
* add slurs to reserved words (#1318)
* add slurs to reserved words (#1314)
* Update reserved.ts
Add slurs to reserved words
* Update reserved.ts
fix typo
* Update reserved.ts to clean up the slur list
* linting
* pluralise
---------
Co-authored-by: jess <jesslarkdev+gh@gmail.com>
* identifier: tweaks and additions to slur list (#1319)
* Refactor appview repo subscription for memleak (#1308)
* refactor to remove closure in loop
* move consecutive item out of p-queue
* Handle validation improvements (#1336)
* Handle matches and false positives for unacceptable words in handles
* move handle validation logic to pds
* missed merge
* add cfg flag
* encode lists
* fix build issues
* move words to cfg
* tidy
---------
Co-authored-by: Jaz Volpert <ericvolp12@gmail.com>
* Allow moderators to take and reverse actor takedowns (#1330)
allow moderators to take and reverse actor takedowns
* ✨ Allow searching reports by moderator did (#1283)
* ✨ Allow searching reports by moderator did
* ✅ Remove .only flags on tests
* ✅ Update snapshot
* ✅ Add checks for did match in actions
* v0.4.1
* Make sequencer leader behavior optional on pds (#1250)
* make sequencer leader behavior optional on pds
* tidy
* use 127.0.0.1 in with-test-db.sh for colima (#1297)
So, since Docker Desktop has licensing issues, some folks use colima for
running containers on their macOS machines (The licensing exempted
CLI-only version of Docker only exists on Linux).
Unfortunately, colima binds host ports only on the IPv4 localhost
address (`127.0.0.1`) while the atproto postgres clients will attempt to
connect to the IPv6 localhost address (`::1`) that macOS sets in
/etc/hosts. See https://github.com/abiosoft/colima/issues/583 and
https://github.com/lima-vm/lima/issues/1330 for the tickets against
colima. (Docker Desktop binds to both IPv4 and IPv6 localhost addresses
and so doesn't have this issue.)
To workaround this silly issue, we can use `localhost` within the docker
containers and docker-compose, but need to set the `DB_POSTGRES_URL` env
var to use the IPv4 localhost explicitly.
(Asking folks to edit /etc/hosts causes other tools to break and will be
overridden on each OS upgrade.)
* Subscription util tests (#1295)
* consecutive list tests
* flesh out subscription util tests
---------
Co-authored-by: Devin Ivy <devinivy@gmail.com>
* Content reporting on record fields (#1351)
* content reporting on record fields
* fix test
* tests
* tidy
* Check rkey contents just for non-tids (#1353)
check rkey content for non-tids
* ✨ Added new procedure for sending admin email (#1312)
* 🚧 Added new lexicon for sending admin email
* ✨ Add moderation mailer
* ✨ Switch to text email content from html
* 🧹 Cleanup some early implementation code and reflect PR reivew
* ✨ Use smtp host instead of gmail service config
* ✨ Move to using single smtp url
* v0.4.2
* Patch up a couple sqlite tests (#1355)
patch up a couple sqlite tests
* enable feeds & build branch
* disable branch building & enable without proxy header
---------
Co-authored-by: Devin Ivy <devinivy@gmail.com>
Co-authored-by: David Buchanan <d@vidbuchanan.co.uk>
Co-authored-by: jess <jesslarkdev+gh@gmail.com>
Co-authored-by: bnewbold <bnewbold@robocracy.org>
Co-authored-by: Jaz Volpert <ericvolp12@gmail.com>
Co-authored-by: Foysal Ahamed <cfaion341@gmail.com>
Co-authored-by: Jeff Hodges <jeff@somethingsimilar.com>
* add optional ilike query to getPopularFeedGenerators
* fix lint
* fix lint
* handle sqlite too in pds only
* fix lint
* v0.4.3
* Include takendown posts for admins (feature branch) (#1361)
* 🚧 WIP including takendown posts on author feed
* ✨ Add takedown id on posts when including taken down posts
* 🧹 Cleanup the auth verifier and other bsky package code
* ✅ Add test for admin getAuthorFeed
* 🧹 Cleanup lexicon and exclude takedownId
* more explicit plumbing for post hydration w/o requester or with takedown info
* pass along flag for soft-deleted actors
* cleanup getAuthorFeed w/ auth
* reorg getAuthorFeed logic around role/access-based auth
---------
Co-authored-by: Foysal Ahamed <cfaion341@gmail.com>
* ✨ Disable signing up with invite code from takendown account (#1350)
* fix viewer data
---------
Co-authored-by: Devin Ivy <devinivy@gmail.com>
Co-authored-by: Foysal Ahamed <cfaion341@gmail.com>
Co-authored-by: Jeff Hodges <jeff@somethingsimilar.com>
Co-authored-by: David Buchanan <d@vidbuchanan.co.uk>
Co-authored-by: jess <jesslarkdev+gh@gmail.com>
Co-authored-by: bnewbold <bnewbold@robocracy.org>
Co-authored-by: Jaz Volpert <ericvolp12@gmail.com>
Co-authored-by: Eric Bailey <git@esb.lol>
* proxy timeline skeleton construction to appview
* add getFeedSkeleton to appview
* mount route
* smart proxy feed skeletons
* tests
* proper error code
* only proxy specific feeds
* build branch
* update proxyable feed logic, should use feed publisher rather than generator
* fix feed proxy tests, configure feed publisher (in addition to generator)
* hotfix: prevent user-supplied rkey on posts with createRecord (#1313)
* prevent user-supplied rkey on posts with createRecord
* allow empty-string rkey parameter
Co-authored-by: devin ivy <devinivy@gmail.com>
---------
Co-authored-by: devin ivy <devinivy@gmail.com>
* add slurs to reserved words (#1318)
* add slurs to reserved words (#1314)
* Update reserved.ts
Add slurs to reserved words
* Update reserved.ts
fix typo
* Update reserved.ts to clean up the slur list
* linting
* pluralise
---------
Co-authored-by: jess <jesslarkdev+gh@gmail.com>
* identifier: tweaks and additions to slur list (#1319)
* Refactor appview repo subscription for memleak (#1308)
* refactor to remove closure in loop
* move consecutive item out of p-queue
* Handle validation improvements (#1336)
* Handle matches and false positives for unacceptable words in handles
* move handle validation logic to pds
* missed merge
* add cfg flag
* encode lists
* fix build issues
* move words to cfg
* tidy
---------
Co-authored-by: Jaz Volpert <ericvolp12@gmail.com>
* Allow moderators to take and reverse actor takedowns (#1330)
allow moderators to take and reverse actor takedowns
* ✨ Allow searching reports by moderator did (#1283)
* ✨ Allow searching reports by moderator did
* ✅ Remove .only flags on tests
* ✅ Update snapshot
* ✅ Add checks for did match in actions
* v0.4.1
* Make sequencer leader behavior optional on pds (#1250)
* make sequencer leader behavior optional on pds
* tidy
* use 127.0.0.1 in with-test-db.sh for colima (#1297)
So, since Docker Desktop has licensing issues, some folks use colima for
running containers on their macOS machines (The licensing exempted
CLI-only version of Docker only exists on Linux).
Unfortunately, colima binds host ports only on the IPv4 localhost
address (`127.0.0.1`) while the atproto postgres clients will attempt to
connect to the IPv6 localhost address (`::1`) that macOS sets in
/etc/hosts. See https://github.com/abiosoft/colima/issues/583 and
https://github.com/lima-vm/lima/issues/1330 for the tickets against
colima. (Docker Desktop binds to both IPv4 and IPv6 localhost addresses
and so doesn't have this issue.)
To workaround this silly issue, we can use `localhost` within the docker
containers and docker-compose, but need to set the `DB_POSTGRES_URL` env
var to use the IPv4 localhost explicitly.
(Asking folks to edit /etc/hosts causes other tools to break and will be
overridden on each OS upgrade.)
* Subscription util tests (#1295)
* consecutive list tests
* flesh out subscription util tests
---------
Co-authored-by: Devin Ivy <devinivy@gmail.com>
* Content reporting on record fields (#1351)
* content reporting on record fields
* fix test
* tests
* tidy
* Check rkey contents just for non-tids (#1353)
check rkey content for non-tids
* ✨ Added new procedure for sending admin email (#1312)
* 🚧 Added new lexicon for sending admin email
* ✨ Add moderation mailer
* ✨ Switch to text email content from html
* 🧹 Cleanup some early implementation code and reflect PR reivew
* ✨ Use smtp host instead of gmail service config
* ✨ Move to using single smtp url
* v0.4.2
* Patch up a couple sqlite tests (#1355)
patch up a couple sqlite tests
* enable feeds & build branch
* disable branch building & enable without proxy header
---------
Co-authored-by: Devin Ivy <devinivy@gmail.com>
Co-authored-by: David Buchanan <d@vidbuchanan.co.uk>
Co-authored-by: jess <jesslarkdev+gh@gmail.com>
Co-authored-by: bnewbold <bnewbold@robocracy.org>
Co-authored-by: Jaz Volpert <ericvolp12@gmail.com>
Co-authored-by: Foysal Ahamed <cfaion341@gmail.com>
Co-authored-by: Jeff Hodges <jeff@somethingsimilar.com>
* 🚧 Added new lexicon for sending admin email
* ✨ Add moderation mailer
* ✨ Switch to text email content from html
* 🧹 Cleanup some early implementation code and reflect PR reivew
* ✨ Use smtp host instead of gmail service config
* ✨ Move to using single smtp url
* setup triage user on pds, update moderator username (invalidates old token)
* initial pass on triage access on pds, limit access to email addrs
* apply moderator vs triage rules on taking and reversing mod actions for pds
* update pds tests for triage auth role
* setup moderator and triage roles on bsky appview
* apply mod and triage access rules to bsky admin endpoints
* reframe admin auth as role-based auth, tidy auth apis
* tidy
* build
* revert change to basic auth username for role-based auth
* add indices
* add record index to bsky
* sync-up bsky index migration, remove duplicate index
* backpressure on bsky backfill indexing (#1268)
* backpressure on bsky backfill indexing
* skip image resolution for text labeler
* increase background queue concurrency for backfill
* tidy
* Proxy timeline skeleton construction (#1264)
proxy timeline skeleton construction to appview
* Only pass through known params on timeline skeleton (#1270)
only pass through own params
* Require headers on getRecord proxy (#1271)
require headers on getRecord proxy
* Add boolean for enabling generic appview proxying (#1273)
* add boolean config for enabling generic proxying
* tweak
* tweak cfg var name
* tweak
* 🐛 Only ignore reports for specific at-uri when ignoreSubject contains at-uri (#1251)
* Move timeline construction to appview (#1274)
full switch timeline construction to appview
* Better propagate errors on repo streams (#1276)
better propgate errors on repo streams
* Log pds sequencer leader stats (#1277)
log pds sequencer leader stats
* Explicit dns servers (#1281)
* add ability to setup explicit dns servers
* cleanup
* fix
* reorder
* pr feedback
* Thread through id-resolver cfg (#1282)
thread through id-resolver-cfg
* Bsky log commit error (#1275)
* don't bail on bad record index
* add build
* temporarily disable check, full reindex on rabase
* don't bail on bad record index during rebase, track last commit on rebase
* log bsky repo subscription stats
* add running and waiting count to repo sub stats
* re-enable fast path for happy rebases
* only hold onto seq in cursor consecutivelist, don't hold onto whole completed messages
* Misc scaling (#1284)
* limit backsearch to 1 day instead of 3
* lower like count threshold
* bump to 6
* disable like count check
* disable with friends
* preemptively cache last commit
* inline list mutes
* actor service
* label cache
* placehodler on popular with friends
* bulk sequence
* no limit but chunk
* bump chunk to 5k
* try 10k
* fix notify
* tweaking
* syntax
* one more fix
* increase backfill allowance
* full refresh label cache
* limit 1 on mute list
* reserve aclu handle
* clean up testing with label cache
* note on with-friends
* rm defer from label cache
* label cache error handling
* rm branch build
* build appview
* update indices
---------
Co-authored-by: Devin Ivy <devinivy@gmail.com>
Co-authored-by: Foysal Ahamed <cfaion341@gmail.com>
* don't bail on bad record index
* add build
* temporarily disable check, full reindex on rabase
* don't bail on bad record index during rebase, track last commit on rebase
* log bsky repo subscription stats
* add running and waiting count to repo sub stats
* re-enable fast path for happy rebases
* only hold onto seq in cursor consecutivelist, don't hold onto whole completed messages
* remove post_hierarchy from db model and indexing in bsky appview
* update bsky appview getPostThread to use recursive query to build thread
* add covering index to speed-up descendents query
* tidy post/notification processing w/o post_hierarchy
* tidy, disallow infinitely following reply cycles
* run with-test-db in monorepo test
* improve pg script
* tidy
* namespace bsky pg schemas
* differentiate schemas
* clean up script
* first pass at invalid handles in appview
* tests for handle invalidation
* move mock to instance instead of prototype
* change network mocks in general
* fixing pagination on actor-search
* fix snap & normalize handles on index
* handling did pagination + update tests
* one last update
* add compression
* compress carfiles
* update package version
* add tests
* one more test
* remove compressible dep
* add gzip to appview
* fix package.json
* sync-up bsky appview to apply takedowns during hydration from #1232
* apply blocks and mutes on bsky appview custom algos
* hit index on with-friends algo pagination
* more performant query for fetching invite codes with uses
* tidy
* simplify query for actor typeahead for maximal use of trigram index
* add cid to ListView and ListViewBasic
* add test for mute list embed
* add support for list embeds views
* test
* port to appview
* update missing snap
---------
Co-authored-by: dholms <dtholmgren@gmail.com>
* Add languages field to post record
* helper for parsing bcp47
* add language format to lexicon
* codegen for post record langs field
* re-export language parsing in api package
* tests and tidy for lexicon language format
* index post langs, in-progress
* update snapshots, fixes record-with-media embed issue
* index post langs on bsky appview
* don't bother indexing post langs in pds appview, tidy
* Don't serve high-level details about taken-down feedgens
* Takedown checks on sync routes
* Use simpler check for takedowns on sync routes
* ensure takendown feedgens are handled in bsky appview
* pds proxy to appview based on headers
* reorg appview routes forwarding mutes to appview
* tidy
* clean up ctx
* track notif state
* use notif state for notif routes
* add back in missing file
* pr feedback
* wip
* more views
* more views
* update snaps & suggestions test
* better choices for like & reposted
* note
* better block test
* Test pds-proxied mute and notif state
* Update bsky snaps, remove unnecessary #postView
* Update bsky notification tests to use updateSeen
* add getList getFeedGen tests
* Re-disconnect pds from in-process appview indexing for tests
* clean up forSnapshot
* tidy
* feed gen view tests
---------
Co-authored-by: Devin Ivy <devinivy@gmail.com>
* Loosen indexing txn boundaries to record-level in bsky appview, no long transactions
* Add explicit HeadNotFound error to sync.getHead
* Update tombstone behavior on bsky appview, use more specific error on sync.getHead
* Model post and profile aggs in bsky
* Add background, onCommit, db and background stats
* Add aggregations for post and profile
* Use background queue in bsky labeler, misc plumbing
* Process background throughout bsky tests
* bsky tidy and fixes
* Build views using agg tables in bsky
* Views of feedgens on bsky
* hook up indexing
* Setup custom feeds on bsky
* graph service + getList routes
* migration
* Feed views refactor for bsky, implement getFeed w/ auth passthrough
* mute lists
* add getListMutes
* mute list tests
* add mutes table & mute/unmuteActor routes
* Passthrough auth from bsky appview to feedgen, fixes/tidy/tests
* add getMutes
* implement mute functionality
* remove unspecced
* mute tests
* mute impl tests
* remove proxy tests
* Test custom algos on bsky
* add mute state to snapshots
* table & indexing plugin
* getBlocks
* bail out of mute subquery when no viewer
* fleshing out services
* Test pds getFeed proxy
* tidy, fix build
* tidy
* Fix minor race in bsky mutelist tests
* blocks in feed views
* db migration, impl block logic & tests
* Update pds proxy snaps based on appview mutes
* missed some files on last commit
* ensure process after unmute
* update snap
* move adminAuth to seedclient param
* apply blocks in getFeed
* update snaps
* upadate one last snap
* pr feedback
---------
Co-authored-by: Devin Ivy <devinivy@gmail.com>
* Misc notification and optimization in bsky, tidy
* Handle notifs on message queue in bsky appview
* Sync-up profile labeling behavior in bsky
* No async work during actor unindexing in bsky, include additional indexes
* Prevent deeply nested notifs w/ hellthread exception in bsky appview
* Add indexes to bsky appview for more efficient actor deletion/unindexing
* Update pds proxy snaps for updated bsky profile labeling
* Return custom suggestions in bsky appview
* Test out-of-order indexing of aggregations on bsky appview
* Proxy pds getPopular to hot-classic feed on appview. Proxy getPopularFeedGenerators to appview.
* Make did field required on feedgen view
* Misc notification and optimization in bsky, tidy
* Handle notifs on message queue in bsky appview
* Sync-up profile labeling behavior in bsky
* No async work during actor unindexing in bsky, include additional indexes
* Prevent deeply nested notifs w/ hellthread exception in bsky appview
* Add indexes to bsky appview for more efficient actor deletion/unindexing
* Update pds proxy snaps for updated bsky profile labeling
* Return custom suggestions in bsky appview
* Model post and profile aggs in bsky
* Add background, onCommit, db and background stats
* Add aggregations for post and profile
* Use background queue in bsky labeler, misc plumbing
* Process background throughout bsky tests
* bsky tidy and fixes
* Build views using agg tables in bsky
* Views of feedgens on bsky
* Setup custom feeds on bsky
* Feed views refactor for bsky, implement getFeed w/ auth passthrough
* Passthrough auth from bsky appview to feedgen, fixes/tidy/tests
* Test custom algos on bsky
* Test pds getFeed proxy
* tidy, fix build
* tidy
* Model post and profile aggs in bsky
* Add background, onCommit, db and background stats
* Add aggregations for post and profile
* Use background queue in bsky labeler, misc plumbing
* Process background throughout bsky tests
* bsky tidy and fixes
* Build views using agg tables in bsky
* Views of feedgens on bsky
* tidy, fix build
* tidy/fix bsky migration