Skip to content

fix: standard site sync#2994

Merged
trueberryless merged 1 commit into
mainfrom
w/ss-fixes
Jul 4, 2026
Merged

fix: standard site sync#2994
trueberryless merged 1 commit into
mainfrom
w/ss-fixes

Conversation

@ghostdevv

Copy link
Copy Markdown
Member

Looks like after #1879 (probably) when the blog post avatars were done at build time, the schema that was being used in the standard site sync code for the blog post frontmatter validation wasn't updated, so it's been failing to sync. I ran this fix so the standard site is working in production, and this should keep it working for future posts.

@vercel

vercel Bot commented Jul 4, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
npmx.dev Ready Ready Preview, Comment Jul 4, 2026 2:42am
2 Skipped Deployments
Project Deployment Actions Updated (UTC)
docs.npmx.dev Ignored Ignored Preview Jul 4, 2026 2:42am
npmx-lunaria Ignored Ignored Jul 4, 2026 2:42am

Request Review

@coderabbitai

coderabbitai Bot commented Jul 4, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: b11bc4c2-c63a-4213-95e3-6ddb7ec6274c

📥 Commits

Reviewing files that changed from the base of the PR and between 2e8fb1d and 09203ba.

📒 Files selected for processing (2)
  • modules/standard-site-sync.ts
  • shared/schemas/blog.ts
🚧 Files skipped from review as they are similar to previous changes (1)
  • modules/standard-site-sync.ts

📝 Walkthrough

Summary by CodeRabbit

  • Bug Fixes
    • Blog synchronisation now validates incoming post data more strictly, helping prevent invalid frontmatter from being processed.
    • New posts and publications now use a more reliable short delay before indexing, improving sync consistency.
  • Refactor
    • Simplified how blog documents are built during synchronisation, with no change to the visible content.

Walkthrough

This change updates blog frontmatter validation to use RawBlogPostSchema, removes siteUrl from buildATProtoDocument, and switches the post-publication delay to node:timers/promises setTimeout. BlogPostSchema is also no longer exported.

Changes

Standard Site Sync Updates

Layer / File(s) Summary
Schema validation update
shared/schemas/blog.ts, modules/standard-site-sync.ts
Frontmatter validation now uses RawBlogPostSchema for safeParse, and BlogPostSchema is no longer exported from the shared schema module.
buildATProtoDocument signature simplification
modules/standard-site-sync.ts
buildATProtoDocument no longer takes a siteUrl parameter; the call site now passes only the validated blog data.
Publication delay mechanism change
modules/standard-site-sync.ts
The post-publication wait now imports setTimeout from node:timers/promises and uses await setTimeout(2_000).
🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly matches the main change: fixing standard site sync after the frontmatter schema update.
Description check ✅ Passed The description directly explains the sync failure and the schema mismatch that this PR fixes.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch w/ss-fixes

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@codecov

codecov Bot commented Jul 4, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ All tests successful. No failed tests found.

📢 Thoughts on this report? Let us know!

@ghostdevv ghostdevv changed the title chore(fix): standard site sync fix: standard site sync Jul 4, 2026
@ghostdevv

Copy link
Copy Markdown
Member Author

thanks to Francisco for noticing: https://bsky.app/profile/frabarz.cl/post/3mpquscaios24

}

const result = safeParse(BlogPostSchema, normalizedFrontmatter)
const result = safeParse(RawBlogPostSchema, normalizedFrontmatter)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(this is the only fix, the other changes are because I can't help myself but tidy up a tiny bit)

@trueberryless trueberryless left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me 🚀

Thanks for the quick fix!

@trueberryless trueberryless added this pull request to the merge queue Jul 4, 2026
Merged via the queue into main with commit e731a54 Jul 4, 2026
27 checks passed
@trueberryless trueberryless deleted the w/ss-fixes branch July 4, 2026 06:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants