feat: implement Bluesky scan posts job and enhance user scanning

- Add new ScanPostsJob for scanning Bluesky posts
- Enhance ScanUserJob with improved error handling and logging
- Update BlueskyPost model with new fields and validation
- Add auxiliary tables for Bluesky posts
- Improve job base classes with better color logging
- Update specs with proper HTTP mocking patterns
- Add factory for BlueskyPost testing
This commit is contained in:
Dylan Knutson
2025-08-10 18:41:01 +00:00
parent 5c71fc6b15
commit eba4b58666
20 changed files with 796 additions and 548 deletions

View File

@@ -14,7 +14,6 @@ class AddAuxTablesForDomainPostsBlueskyPosts < ActiveRecord::Migration[7.2]
t.text :text # Post content
# Post metadata (posted_at is in main table)
t.datetime :bluesky_created_at, index: true
t.datetime :scanned_at
t.string :language

View File

@@ -1413,7 +1413,6 @@ CREATE TABLE public.domain_posts_bluesky_aux (
bluesky_rkey character varying NOT NULL,
at_uri character varying,
text text,
bluesky_created_at timestamp(6) without time zone,
scanned_at timestamp(6) without time zone,
language character varying,
like_count integer,
@@ -4381,13 +4380,6 @@ CREATE INDEX index_domain_post_groups_on_type ON public.domain_post_groups USING
CREATE INDEX index_domain_posts_bluesky_aux_on_base_table_id ON public.domain_posts_bluesky_aux USING btree (base_table_id);
--
-- Name: index_domain_posts_bluesky_aux_on_bluesky_created_at; Type: INDEX; Schema: public; Owner: -
--
CREATE INDEX index_domain_posts_bluesky_aux_on_bluesky_created_at ON public.domain_posts_bluesky_aux USING btree (bluesky_created_at);
--
-- Name: index_domain_posts_bluesky_aux_on_bluesky_rkey; Type: INDEX; Schema: public; Owner: -
--