Skip to content

fix(ci): always create sync commit for child repo updates - #35

Merged
mateodelnorte merged 1 commit into
mainfrom
fix/notify-parent-regex
Feb 19, 2026
Merged

mateodelnorte merged 1 commit into
mainfrom
fix/notify-parent-regex

Conversation

@mateodelnorte

@mateodelnorte mateodelnorte commented Feb 18, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Removes the feat/fix gate from on-child-update.yml — all child repo merges now create sync commits in the parent
  • Release-please still only includes feat/fix in changelogs, so the release PR remains curated
  • Part of [[tasks/meta-64]] / [[incidents/notify-parent-broken]]

Test plan

  • Merge a child repo PR after the regex fix lands — verify sync commit appears in parent

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Chores

    • Consolidated payload and input handling to use environment variables for consistent outputs.
    • Added a unified output writer to standardize how workflow outputs are emitted.
    • Removed explicit gating so sync and commit steps now follow environment-driven inputs.
    • Logging updated to read from environment-driven outputs for clearer traceability.
  • Tests

    • Minor test comment wording updated for clarity.

@coderabbitai

coderabbitai Bot commented Feb 18, 2026 •

Copy link
Copy Markdown

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉


Walkthrough

Unified payload handling in the GitHub Actions workflow by extracting inputs into environment variables, introduced a write_output helper, removed the explicit release-worthiness gate, and adjusted downstream steps to read env-driven values; a single comment in tests/worktree_cloud.bats was renamed ("Destroy" → "Remove").

Changes

Cohort / File(s) Summary
GitHub Actions workflow
.github/workflows/on-child-update.yml
Extract payload and inputs into environment variables (EVENT_NAME, DISPATCH_*, INPUT_*), add write_output helper to append to GITHUB_OUTPUT, remove the prior gating step, and make commit/create/log steps consume env-driven values instead of conditional step outputs.
Test comment
tests/worktree_cloud.bats
Non-functional comment change: # Destroy → # Remove above the git worktree remove invocation.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Possibly related PRs

Poem

🐰 I nudged the payloads into tidy rows,
I hopped past gates where old logic froze,
Env-vars hum the steps in softer tones,
Commits and logs now speak in shared bones,
🥕 a little hop to mark these cozy flows.

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: removing the feat/fix gate so sync commits are always created for child repo updates.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix/notify-parent-regex

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

@greptile-apps

greptile-apps Bot commented Feb 18, 2026

Copy link
Copy Markdown

Greptile Summary

Removes the feat/fix gate from the child repo update workflow so all child repo merges now create sync commits in the parent repo. This ensures the parent repo history always reflects child repo changes, while release-please continues to only include feat/fix commits in changelogs. The test files are updated to use the renamed remove command (from destroy) for worktree cleanup, with backward compatibility preserved through an alias.

Key changes:

  • Removed Check if release-worthy step that filtered commits by type
  • Removed conditional from Create sync commit step (now always runs)
  • Updated test suite to use remove instead of destroy command
  • Added test to verify destroy alias still works for backward compatibility

Confidence Score: 5/5

  • This PR is safe to merge with minimal risk
  • The changes are straightforward and well-tested. The workflow simplification removes unnecessary filtering logic, and the test updates correctly reflect the command rename while maintaining backward compatibility. No breaking changes or edge cases identified.
  • No files require special attention

Important Files Changed

Filename Overview
.github/workflows/on-child-update.yml Removed feat/fix gate - all child repo merges now create sync commits in parent repo
tests/worktree.bats Updated tests to use remove command instead of destroy, added test for destroy alias compatibility
tests/worktree_cloud.bats Updated tests to use remove command, updated test names and help text assertions

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Child Repo Merge] --> B[Trigger on-child-update.yml]
    B --> C[Extract Payload]
    C --> D{Before: Check Type}
    D -->|feat or fix| E[Create Sync Commit]
    D -->|other types| F[Skip - No Commit]
    
    B2[After This PR] --> C2[Extract Payload]
    C2 --> E2[Always Create Sync Commit]
    E2 --> G[Push to Parent Main]
    G --> H[Release-Please Processes All Commits]
    H --> I{Commit Type?}
    I -->|feat or fix| J[Include in Changelog/Release]
    I -->|other types| K[Track But Don't Release]
    
    style D fill:#ffcccc
    style F fill:#ffcccc
    style E2 fill:#ccffcc
    style J fill:#ccffcc
    style K fill:#ffffcc
Loading

Last reviewed commit: db5a49a

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
tests/worktree_cloud.bats (1)

295-318: ⚠️ Potential issue | 🟡 Minor

Stale comment at line 307.

The comment # Destroy should be updated to # Remove to match the renamed command.

📝 Proposed fix
     # Verify entry exists
     python3 -c "
 import json
 with open('$STORE') as f:
     data = json.load(f)
 assert any(v['name'] == 'store-rm' for v in data['worktrees'].values())
 "

-    # Destroy
+    # Remove
     run "$META_BIN" git worktree remove store-rm
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/worktree_cloud.bats` around lines 295 - 318, Update the stale inline
comment in the test "worktree remove removes from centralized store": change the
comment above the command invocation of "$META_BIN" git worktree remove store-rm
from "# Destroy" to "# Remove" so the comment matches the renamed remove command
and clarifies intent.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Outside diff comments:
In `@tests/worktree_cloud.bats`:
- Around line 295-318: Update the stale inline comment in the test "worktree
remove removes from centralized store": change the comment above the command
invocation of "$META_BIN" git worktree remove store-rm from "# Destroy" to "#
Remove" so the comment matches the renamed remove command and clarifies intent.

@mateodelnorte
mateodelnorte force-pushed the fix/notify-parent-regex branch 2 times, most recently from c5e4cb4 to 2096614 Compare February 18, 2026 23:21

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In @.github/workflows/on-child-update.yml:
- Around line 42-70: The current writes to $GITHUB_OUTPUT using echo
"key=$VALUE" are unsafe for multiline or untrusted values (e.g., commit
messages); update the "Extract payload" step to use GitHub Actions multiline
output syntax for each output (repo_name, short_sha, message, type, actor):
instead of echo "key=$VAR" >> $GITHUB_OUTPUT, write a delimiter line like
"key<<EOF" to $GITHUB_OUTPUT, then write the raw $VAR content on the next
line(s) and close with "EOF" to ensure values with newlines or special
characters are preserved and cannot inject extra keys; apply this change for
both the repository_dispatch branch (DISPATCH_*) and the workflow_dispatch
branch (INPUT_*) writes.

Comment thread .github/workflows/on-child-update.yml
@mateodelnorte
mateodelnorte force-pushed the fix/notify-parent-regex branch from 2096614 to 9e38d04 Compare February 19, 2026 00:20

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Duplicate comments:
In @.github/workflows/on-child-update.yml:
- Around line 44-69: Replace the unsafe single-line appends to $GITHUB_OUTPUT
(e.g., echo "repo_name=$DISPATCH_REPO_NAME" >> $GITHUB_OUTPUT) with the
multiline-safe heredoc style that protects against newlines and output
injection: for each key (repo_name, short_sha, message, type, actor) write the
key line with a delimiter then append the variable value and the closing
delimiter into $GITHUB_OUTPUT (for example echo "repo_name<<EOF" >>
$GITHUB_OUTPUT; echo "$DISPATCH_REPO_NAME" >> $GITHUB_OUTPUT; echo "EOF" >>
$GITHUB_OUTPUT), doing this for both the DISPATCH_* and INPUT_* branches in the
run block so multiline commit messages and untrusted input are safely written.

@mateodelnorte
mateodelnorte force-pushed the fix/notify-parent-regex branch from 9e38d04 to 3749c54 Compare February 19, 2026 00:27
Remove the feat/fix gate from on-child-update.yml — all child repo
merges now create sync commits in the parent. Release-please still only
includes feat/fix in changelogs, so the release PR remains curated.

Also hardens both workflows against command injection by moving all
${{ }} expressions into env: blocks, and fixes a stale "Destroy"
comment in worktree_cloud.bats.

Implements [[tasks/meta-64]]

Co-authored-by: Claude <claude@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@mateodelnorte
mateodelnorte force-pushed the fix/notify-parent-regex branch from 3749c54 to 0ff8306 Compare February 19, 2026 03:23
@mateodelnorte
mateodelnorte merged commit 1f0e06c into main Feb 19, 2026
8 checks passed
@mateodelnorte
mateodelnorte deleted the fix/notify-parent-regex branch February 19, 2026 04:02
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.

1 participant