Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Caution Review failedThe pull request is closed. WalkthroughThe Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes ✨ Finishing Touches
🧪 Generate unit tests (beta)
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 |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f4fa3016e8
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if [ "$EPHEMERAL_VALIDATOR_STARTED_BY_US" = true ]; then | ||
| pkill -f "ephemeral-validator" 2>/dev/null || true | ||
| echo -e "\n[SETUP] ${YELLOW}Cleaning up validators...${NC}" | ||
| if ! is_truthy "$SKIP_LOCAL_VALIDATOR"; then |
There was a problem hiding this comment.
Clean up validators started by this script in skip mode
When SKIP_LOCAL_VALIDATOR is true, cleanup() skips all process termination under if ! is_truthy "$SKIP_LOCAL_VALIDATOR", but the script can still start ephemeral-validator itself earlier (when port 7799 is free). In that flow, the process is left running after tests, so later runs may attach to stale state on port 7799 instead of a fresh reset, which can corrupt test reliability and cause hard-to-reproduce failures.
Useful? React with 👍 / 👎.
| } | ||
|
|
||
| has_anchor_cli_skip_local_validator() { | ||
| if pgrep -af "anchor" 2>/dev/null | awk '($0 ~ /test/) && ($0 ~ /--skip-local-validator/) { found=1; exit } END { exit (found?0:1) }'; then |
There was a problem hiding this comment.
Limit skip-local-validator auto-detection to this process tree
has_anchor_cli_skip_local_validator() scans all system processes with pgrep -af "anchor" and sets SKIP_LOCAL_VALIDATOR if any matching command includes test and --skip-local-validator, even if that command is unrelated to this run. In shared dev/CI hosts, an unrelated Anchor test can therefore force this script into skip mode, and the later skip-local-validator branch will fail if no validator is already on port 8899 instead of starting one.
Useful? React with 👍 / 👎.
Summary by CodeRabbit
New Features
Chores