Skip to content

fix(ci): establish baseline before content check to prevent false positives#18

Merged
sonupreetam merged 1 commit into
complytime:mainfrom
sonupreetam:017-fix-false-positive-content-changes
May 21, 2026
Merged

fix(ci): establish baseline before content check to prevent false positives#18
sonupreetam merged 1 commit into
complytime:mainfrom
sonupreetam:017-fix-false-positive-content-changes

Conversation

@sonupreetam
Copy link
Copy Markdown
Contributor

Summary

  • The weekly content sync workflow always reported all 32 files as "changed" on every run — even when upstream content was identical — because writeFileSafe had no baseline to compare against on a fresh CI runner (content/docs/projects/*/ is gitignored).
  • Adds a preliminary --write step using the committed lock SHAs to populate the runner's disk before --update-lock and the actual content check, so writeFileSafe can detect only genuine content differences.
  • No code changes to the sync tool; workflow-only fix.

Evidence: PR #15 and PR #16 list the identical 32 files across the same 5 repos — only pinned SHAs differ.

Fixes #17

Test plan

  • Trigger workflow manually (workflow_dispatch) or wait for next weekly cron
  • If no upstream docs changed: verify no PR is created (has_changes=false)
  • If upstream docs changed: verify PR lists only the actually changed files, not all 32

Made with Cursor

…itives

The sync workflow always reported all files as changed because
writeFileSafe had no baseline to compare against on a fresh runner.
Add a preliminary --write step with the current (committed) lock SHAs
so the subsequent check step can detect only genuine content changes.

Fixes complytime#17

Co-authored-by: Cursor <cursoragent@cursor.com>
Copy link
Copy Markdown
Member

@marcusburghardt marcusburghardt left a comment

Choose a reason for hiding this comment

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

LGTM

@sonupreetam sonupreetam removed the request for review from trevor-vaughan May 21, 2026 08:21
@sonupreetam sonupreetam merged commit 311c664 into complytime:main May 21, 2026
12 checks passed
@sonupreetam sonupreetam deleted the 017-fix-false-positive-content-changes branch May 21, 2026 08:21
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.

Content sync always reports all files as changed on fresh CI runner

2 participants