Skip to content

fix(#3446): remove invalid top-level return guard from inlined CSMA code#3448

Open
fullsend-ai-coder[bot] wants to merge 1 commit into
mainfrom
agent/3446-remove-csma-load-guard
Open

fix(#3446): remove invalid top-level return guard from inlined CSMA code#3448
fullsend-ai-coder[bot] wants to merge 1 commit into
mainfrom
agent/3446-remove-csma-load-guard

Conversation

@fullsend-ai-coder

Copy link
Copy Markdown
Contributor

Summary

  • Removes the two-line library-style load guard ([[ -n "${GITHUB_API_CSMA_SH_LOADED:-}" ]] && return 0 / GITHUB_API_CSMA_SH_LOADED=1) from post-prioritize.sh and post-prioritize-test.sh
  • These guards were left over from when the CSMA library was inlined (PR fix(prioritize): inline CSMA library into post-script #3182) and cause a crash (return: can only 'return' from a function or sourced script, exit code 2) when GITHUB_API_CSMA_SH_LOADED is set in the environment

Closes #3446

Test plan

  • GITHUB_API_CSMA_SH_LOADED=1 bash post-prioritize.sh no longer crashes with a return error (exits with missing env var error instead, as expected)
  • All 7 post-prioritize tests pass via bash internal/scaffold/fullsend-repo/scripts/post-prioritize-test.sh
  • shellcheck passes clean on both files (not available in sandbox; CI will verify)

🤖 Generated with Claude Code

The CSMA library load guard (`return 0` at top level) was left in when
the library was inlined into post-prioritize.sh and its test file. Since
these scripts are executed directly (not sourced), `return` at top level
is invalid bash and crashes the script with exit code 2 when
GITHUB_API_CSMA_SH_LOADED is set in the environment.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@fullsend-ai-coder fullsend-ai-coder Bot requested a review from a team as a code owner July 7, 2026 22:57
@github-actions

github-actions Bot commented Jul 7, 2026

Copy link
Copy Markdown

E2E tests did not run

E2E tests run automatically for org/repo members and collaborators on pull requests.

For other contributors, a maintainer must add the ok-to-test label after the latest push.

See E2E testing guide for details.

1 similar comment
@github-actions

github-actions Bot commented Jul 7, 2026

Copy link
Copy Markdown

E2E tests did not run

E2E tests run automatically for org/repo members and collaborators on pull requests.

For other contributors, a maintainer must add the ok-to-test label after the latest push.

See E2E testing guide for details.

@github-actions

github-actions Bot commented Jul 7, 2026

Copy link
Copy Markdown

Site preview

Preview: https://e83941bf-site.fullsend-ai.workers.dev

Commit: 080d81fbf1121e9945b302cb840774aa6b28bbaa

@codecov

codecov Bot commented Jul 7, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

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.

Remove invalid top-level return 0 guard from inlined CSMA code in post-prioritize scripts

0 participants