Skip to content

refactor: move benchmarks to benchmark/ and deduplicate init logic#2885

Open
pdrobnjak wants to merge 3 commits intomainfrom
pd/benchmark-compare
Open

refactor: move benchmarks to benchmark/ and deduplicate init logic#2885
pdrobnjak wants to merge 3 commits intomainfrom
pd/benchmark-compare

Conversation

@pdrobnjak
Copy link
Contributor

@pdrobnjak pdrobnjak commented Feb 13, 2026

Summary

  • Move benchmark scripts from scripts/ to top-level benchmark/ directory
  • Add env vars (SEI_HOME, PORT_OFFSET, SEID_BIN, BENCHMARK_PHASE, LOG_FILE) to benchmark.sh for phase gating and multi-instance support
  • Rewrite benchmark-compare.sh as a thin orchestrator that delegates init/start to benchmark.sh instead of duplicating ~120 lines of chain init logic
  • Add benchmark/CLAUDE.md with benchmark documentation; global CLAUDE.md references it

Test plan

  • benchmark/benchmark.sh with no new env vars behaves identically to the original scripts/benchmark.sh
  • BENCHMARK_PHASE=init SEI_HOME=/tmp/test-bench/data benchmark/benchmark.sh inits a chain in /tmp/test-bench/data and exits
  • BENCHMARK_PHASE=start SEI_HOME=/tmp/test-bench/data LOG_FILE=/tmp/test.log benchmark/benchmark.sh starts seid using that data dir
  • benchmark/benchmark-compare.sh baseline=HEAD~1 candidate=HEAD runs a full comparison using benchmark.sh for init/start

🤖 Generated with Claude Code

pdrobnjak and others added 2 commits February 13, 2026 13:10
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…ogic

benchmark-compare.sh duplicated ~120 lines of chain init/config from
benchmark.sh. This refactor adds env vars (SEI_HOME, PORT_OFFSET,
SEID_BIN, BENCHMARK_PHASE, LOG_FILE) to benchmark.sh and rewrites
benchmark-compare.sh as a thin orchestrator that delegates init/start
via those env vars.

- Move scripts/benchmark.sh -> benchmark/benchmark.sh
- Move scripts/benchmark-compare.sh -> benchmark/benchmark-compare.sh
- Move scripts/scenarios/ -> benchmark/scenarios/
- Add benchmark/CLAUDE.md with benchmark docs
- Update path references in scenarios/README.md and app/benchmark/benchmark.go
- Global CLAUDE.md references benchmark/CLAUDE.md for benchmark context

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@github-actions
Copy link

github-actions bot commented Feb 13, 2026

The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedFeb 13, 2026, 1:44 PM

- Add missing env vars (MOCK_BALANCES, DISABLE_INDEXER, DURATION)
- Split env var table by script (benchmark.sh vs benchmark-compare.sh)
- Document GIGA_EXECUTOR/GIGA_OCC default difference between scripts
- Fix TPS extraction example to use LOG_FILE instead of nonexistent path
- Note pprof auto-capture is compare-only; single runs need manual capture
- Add scenario file listing and usage example
- Document DB_BACKEND forwarding in compare script
- Note minimum 2 scenarios required for compare

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@codecov
Copy link

codecov bot commented Feb 13, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 57.18%. Comparing base (7fb1494) to head (127ed99).
⚠️ Report is 6 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2885      +/-   ##
==========================================
+ Coverage   57.16%   57.18%   +0.02%     
==========================================
  Files        2091     2091              
  Lines      171179   171179              
==========================================
+ Hits        97853    97891      +38     
+ Misses      64616    64578      -38     
  Partials     8710     8710              
Flag Coverage Δ
sei-chain 52.64% <ø> (+0.02%) ⬆️
sei-cosmos 48.14% <ø> (ø)
sei-db 68.72% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
app/benchmark/benchmark.go 60.00% <ø> (ø)

... and 33 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants