Repository navigation
feat(pm-dispatch): prompt-file / prompt-url inputs for dispatch actions (#2672 part 4) - #2682
Conversation
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 41 minutes. View limit details
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. Comment |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Part of #2672
Part 4: add prompt-source inputs to the two pm-dispatch reusable actions so scheduled workflows (Part 5) can keep prompts in repo files instead of inline YAML strings. Action-side only — no server change.
Changes
Both
.github/actions/pm-dispatch-startand.github/actions/pm-dispatch-queue:prompt-fileandprompt-url; the existingpromptinput is no longer required at the YAML level (composite actions cannot express one-of — the step enforces it in bash).prompt-file— path relative to the caller's workspace ($GITHUB_WORKSPACE; the caller must check out first), read withcat. A missing or empty file fails the step.prompt-url— an https URL fetched withcurl -fsS. A non-https URL, a fetch error, or an empty body fails the step.prompt— the inline input.promptfield in both actions. Everything else is unchanged: OIDC fetch, error surfacing, outputs, and the token is never printed.Docs:
pm-stack/dispatch/examples/dispatch-workflow.yml: the queue job now demonstratesprompt-file(with anactions/checkoutstep first); both action references stay@main.pm-stack/dispatch/README.md: the "GitHub Actions (reusable)" section documentsprompt/prompt-file/prompt-urland the resolution order.Validation
bash -non both extracted step scripts (OK).curl(OIDC mint, prompt-url fetch, and the dispatch POST, capturing the payload), from a working directory outside the test workspace — 10 cases per action, all passing:[ "$prompt_path" != /* ]glob-expanded/*, breaking relative-path resolution outside the workspace CWD. Replaced with acasepattern; all cases then pass.Need help on this PR? Tag
@codesmith-botwith what you need.