Extract shared verify script helpers and remove legacy TimeCurve script #324
Labels
No labels
agent:fix_bugfix
agent:fix_conflicts
agent:fix_security
agent:gap_analysis
agent:implement
agent:open_issues
agents
agent:security_audit
agent:verify
area
timecurve
arena
arena-v2
audit
block:feature_review
block:security
bug
contracts
design
devops
docs
documentation
enhancement
epic
feature
frontend
indexer
low priority
megaeth
operations
ops
performance
QA
qa checklist
referrals
removal
security
smart-contracts
tech-debt
testing
time-arena
timecurve
visual-qa
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
code/yieldomega#324
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Parent
Gap analysis follow-up from #309.
Current codebase
DRY debt: Seven indexer-backed verify scripts duplicate ~80–140 lines each (Anvil spawn, deploy, Postgres reset, indexer wait):
verify-podium-live-anvil.sh,verify-wallet-profile-anvil.sh,verify-vault-funding-anvil.sh,verify-podium-prize-preview-anvil.sh,verify-last-buy-epoch-anvil.sh,verify-indexer-rpc-metrics.sh,verify-donate-pools-anvil.shShared libs exist:
scripts/lib/anvil_deploy_dev.sh,kumbaya_local_anvil_env.sh— noverify_anvil_common.sh/verify_indexer_stack.sh.Legacy:
scripts/verify-timecurve-post-end-gates-anvil.sh— v1 TimeCurveended()/redeemCharms; incompatible with Arena v2. Approved: remove.Dead links:
docs/testing/e2e-anvil.md→ missingfrontend/e2e/anvil-collection.spec.tsdocs/frontend/arena-views.mdbroken relative pathsdocs/testing/frontend-content-audit.md→ missing#pay-modesanchorWhy needed
Approved: Extract shared verify helpers; remove legacy TimeCurve script; fix doc dead links.
Constraints / guardrails
verify-timecurve-buy-router-anvil.shdelegates toverify-time-arena-buy-router-anvil.sh.Relevant files
scripts/verify-*-anvil.sh(listed above)scripts/lib/— new shared modulesscripts/verify-timecurve-post-end-gates-anvil.sh(delete)contracts/script/anvil_rich_state.sh(references legacy script)docs/testing/e2e-anvil.md,docs/frontend/arena-views.mdscripts/check-doc-anchors.shRecommended direction
scripts/lib/verify_anvil_common.sh(warp, anvil_send, start/wait) andscripts/lib/verify_indexer_stack.sh(PG reset, indexer spawn,/v1/status).verify-timecurve-post-end-gates-anvil.sh; remove references inanvil_rich_state.sh, audits.check-doc-anchors.shif feasible.Acceptance criteria
e2e-anvil.mdlinks only existing spec files.bash scripts/verify-podium-live-anvil.shstill PASS.Test plan
bash scripts/verify-podium-live-anvil.shbash scripts/verify-wallet-profile-anvil.shbash scripts/verify-evm-dev-wallet-seed-anvil.sh(regression)bash scripts/check-doc-anchors.shif extendedAttack / abuse test plan
pkillscope dangerously.Verification criteria
rg verify-timecurve-post-endreferences except CHANGELOG/history.mentioned in issue #309
mentioned in commit
c543a83d73mentioned in merge request !471
Requires gas optimization. WarBow is expected to have 100s to thousands of participants. Make sure to test gas on large boards & use a more optimized solution.
mentioned in commit
38bedf55afmentioned in merge request !480
mentioned in commit
c602d64379mentioned in merge request !489
mentioned in commit
fc23dc3381Verification — #324 (agent:verify)
Branch checked:
main@1b4f6260(includes mergefc23dc33— MR !489).Acceptance criteria
scripts/lib/verify_anvil_common.sh+scripts/lib/verify_indexer_stack.shexist; sourced by 6 scripts (verify-podium-live-anvil,verify-wallet-profile-anvil,verify-vault-funding-anvil,verify-podium-prize-preview-anvil,verify-last-buy-epoch-anvil,verify-donate-pools-anvil,verify-indexer-rpc-metrics).bash scripts/test-verify-anvil-lib.sh→PASS (6 verify scripts use shared stack lib).scripts/verify-timecurve-post-end-gates-anvil.shabsent;test-verify-anvil-lib.shlegacy-ref gate PASS (allowed refs only in audits/CHANGELOG/docs note).e2e-anvil.mdlinks only existing spec filesanvil-collection.spec.tsreferences; linked specs exist underfrontend/e2e/anvil-*.spec.ts+anvil-referrals.spec.ts.bash scripts/verify-podium-live-anvil.shstill PASScargo test --test integration_stage2withpostgres_stage2_persist_all_events_and_rollback_after: APIblock_timestamp="1700000000"vs DBEXTRACT(EPOCH...)::text="1700000000.000000"(integration_stage2.rs:799). API usesFLOOR(EXTRACT(EPOCH...))::bigint::text(api_arena.rs:370); test DB parity query does not — unrelated to #324 shared-lib refactor, likely post-merge regression. Exit code 101.Test plan
bash scripts/verify-podium-live-anvil.shbash scripts/verify-wallet-profile-anvil.shintegration_stage2gate at script tail — expected FAIL for same assertion.bash scripts/verify-evm-dev-wallet-seed-anvil.shbash scripts/check-doc-anchors.shbash scripts/test-verify-anvil-lib.shpkill, ≥5 script sourcing, legacy removal.bash scripts/verify-cloud-postgres.shVerification criteria (issue body)
test-verify-anvil-lib.shenforces sourcing.verify-timecurve-post-endrefs outside historytest-verify-anvil-lib.shgate;audits/historical mention allowed.pkill -f "anvil.*${port}"only; no barepkill anvil.Doc dead-link fixes (issue scope)
docs/testing/e2e-anvil.mddocs/frontend/arena-views.mdrelative pathscheck-doc-anchors.shdocs/testing/frontend-content-audit.md#pay-modesOverall
#324 implementation on
mainlooks complete, but the issue cannot be closed whileverify-podium-live-anvil.shfails its explicit acceptance gate.Follow-up
integration_stage2.rsDB parity query to match API (FLOOR(EXTRACT(EPOCH FROM block_timestamp))::bigint::text) or compare numerically — unblocksverify-podium-live-anvil.shandverify-wallet-profile-anvil.sh.mentioned in merge request !498
mentioned in commit
d2913027b4Verification — #324 (agent:verify)
Branch checked:
main@ current HEAD (includes MR !489 shared-lib refactor).Acceptance criteria
scripts/lib/verify_anvil_common.sh+scripts/lib/verify_indexer_stack.shexist; sourced by 7 scripts (verify-podium-live-anvil,verify-wallet-profile-anvil,verify-vault-funding-anvil,verify-podium-prize-preview-anvil,verify-last-buy-epoch-anvil,verify-donate-pools-anvil,verify-indexer-rpc-metrics).bash scripts/test-verify-anvil-lib.sh→PASS (6 verify scripts use shared stack lib).scripts/verify-timecurve-post-end-gates-anvil.shabsent;test-verify-anvil-lib.shlegacy-ref gate PASS (allowed refs only in audits/CHANGELOG/docs note).e2e-anvil.mdlinks only existing spec filesanvil-collection.spec.tsreferences; linked specs exist underfrontend/e2e/anvil-*.spec.ts+anvil-referrals.spec.ts.bash scripts/verify-podium-live-anvil.shstill PASSintegration_stage2(4 tests) all OK.Test plan
bash scripts/verify-podium-live-anvil.sh=== verify-podium-live-anvil: OK ===bash scripts/verify-wallet-profile-anvil.shintegration_stage2tail as podium-live — that gate now PASS (see below).bash scripts/verify-evm-dev-wallet-seed-anvil.shbash scripts/check-doc-anchors.shbash scripts/test-verify-anvil-lib.shpkill, ≥5 script sourcing, legacy removal.bash scripts/verify-cloud-postgres.shcargo test --test integration_stage2 postgres_stage2_persist_all_events_and_rollback_afterblock_timestampvs DBEXTRACTformatting) is fixed onmain; DB parity query usesFLOOR(EXTRACT(EPOCH...))::bigint::textmatching API.Verification criteria (issue body)
test-verify-anvil-lib.shenforces sourcing.verify-timecurve-post-endrefs outside historytest-verify-anvil-lib.shgate;audits/historical mention allowed.pkill -f "anvil.*${port}"only; no barepkill anvil.Doc dead-link fixes (issue scope)
docs/testing/e2e-anvil.mddocs/frontend/arena-views.mdrelative pathscheck-doc-anchors.shdocs/testing/frontend-content-audit.md#pay-modesOverall
All #324 acceptance criteria PASS on
main. Closing issue.