fix: isolate benchmark-compare.sh for parallel invocations#2898
Merged
pdrobnjak merged 1 commit intopd/benchmark-profiling-improvementsfrom Feb 17, 2026
Merged
Conversation
Running 3+ benchmark-compare.sh instances concurrently failed because
5 shared resources were not namespaced: /tmp/sei-bench, ~/.sei,
~/go/bin/seid, git working tree, and network ports.
Changes:
- RUN_ID (default: PID) namespaces BASE_DIR as /tmp/sei-bench-${RUN_ID}/
- RUN_PORT_OFFSET auto-claimed via atomic mkdir slots (supports 30
concurrent runs)
- Replace git checkout with git worktrees for isolated builds
- Replace ~/go/bin/seid with GOBIN-based builds per label
- Replace ~/.sei staging with mktemp in benchmark.sh
- Add --home to all seid commands during init
- Pass SEI_HOME_DIR/SEID_BIN env vars to populate_genesis_accounts.py
- Remove branch save/restore and ~/go/bin/seid copy
- Fix pre-existing double lifecycle bug (parent + child both managing
profiling/timing) by passing DURATION=0 to child start-phase
All defaults are backward-compatible — zero behavior change for
existing single-instance callers.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).
|
62fcfd8
into
pd/benchmark-profiling-improvements
13 of 15 checks passed
Codecov Report✅ All modified and coverable lines are covered by tests.
Additional details and impacted files@@ Coverage Diff @@
## pd/benchmark-profiling-improvements #2898 +/- ##
========================================================================
- Coverage 57.19% 48.35% -8.84%
========================================================================
Files 2091 671 -1420
Lines 171173 50615 -120558
========================================================================
- Hits 97897 24474 -73423
+ Misses 64557 24000 -40557
+ Partials 8719 2141 -6578
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
BASE_DIRper run viaRUN_ID(defaults to PID):/tmp/sei-bench-${RUN_ID}/mkdir(supports 30 concurrent runs, zero coordination)git checkoutwith git worktrees for isolated builds (no working tree collisions)~/go/bin/seidwithGOBIN-based builds per label (no binary collisions)~/.seistaging withmktemp+--homeon allseidcommands (no init collisions)SEI_HOME_DIR/SEID_BINenv vars topopulate_genesis_accounts.py(backward-compatible defaults)DURATION=0to child start-phaseTest plan
bash -non both shell scripts,py_compileon Pythonbenchmark-compare.shruns withDURATION=120— both completed, separateBASE_DIRs, no port conflictspprof -diff_baseproduces valid analyzable output from both runs🤖 Generated with Claude Code