Commit graph

1192 commits

Author SHA1 Message Date
openhands
5741e84552 fix: services/txnBot still has dead recenterAccess read infrastructure (#887)
Remove recenterAccess.ts, recenterAccess.test.ts, the ABI entry, and
getRecenterAccessReader() from BlockchainService. Simplify
getRecenterAccessStatus in service.ts to return open access (hasAccess: true)
since the on-chain recenterAccess() guard no longer exists.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-17 12:50:58 +00:00
johba
0042ff1b5e Merge pull request 'fix: Staking pool exclusion also has an undocumented conditional guard (#889)' (#916) from fix/issue-889 into master 2026-03-17 13:38:05 +01:00
openhands
3770fa9554 fix: Staking pool exclusion also has an undocumented conditional guard (#889) 2026-03-17 12:16:45 +00:00
johba
5c68264127 Merge pull request 'fix: onchain/AGENTS.md:71 missing conditional guard on feeDestination/stakingPool exclusion (#891)' (#915) from fix/issue-891 into master 2026-03-17 13:06:39 +01:00
openhands
ad7a45a40e fix: onchain/AGENTS.md:71 missing conditional guard on feeDestination/stakingPool exclusion (#891) 2026-03-17 11:37:12 +00:00
johba
1ff2269d16 Merge pull request 'fix: ARCHITECTURE.md staking pool bullet missing its own conditional guard (#892)' (#912) from fix/issue-892 into master 2026-03-17 12:27:19 +01:00
openhands
7628e428c7 fix: ARCHITECTURE.md staking pool bullet missing its own conditional guard (#892) 2026-03-17 11:05:54 +00:00
openhands
296c7a2dea fix: ARCHITECTURE.md staking pool bullet missing its own conditional guard (#892) 2026-03-17 10:49:05 +00:00
openhands
f491f30f90 fix: ARCHITECTURE.md staking pool bullet missing its own conditional guard (#892) 2026-03-17 10:26:47 +00:00
johba
e12dad3a84 Merge pull request 'fix: onchain/analysis/PARAMETER_SEARCH_RESULTS.md shows stale unconditional pseudocode (#893)' (#910) from fix/issue-893 into master 2026-03-17 11:16:14 +01:00
openhands
a8e186caac fix: onchain/analysis/PARAMETER_SEARCH_RESULTS.md shows stale unconditional pseudocode (#893)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-17 09:47:37 +00:00
johba
4c040e6a30 Merge pull request 'fix: txn-bot has no depends_on: ponder in docker-compose (#898)' (#907) from fix/issue-898 into master 2026-03-17 09:24:36 +01:00
openhands
822683fd4f ci: retrigger after infra failure 2026-03-17 07:57:45 +00:00
openhands
f323a00f55 fix: txn-bot has no depends_on: ponder in docker-compose (#898) 2026-03-17 07:47:12 +00:00
johba
6a4831c51c Merge pull request 'fix: txn-bot port 43069 not published to host (#899)' (#906) from fix/issue-899 into master 2026-03-17 08:36:27 +01:00
openhands
1d121ab24f fix: txn-bot port 43069 not published to host (#899)
Add ports mapping 127.0.0.1:43069:43069 to txn-bot service in
docker-compose.yml, matching the pattern used by ponder. Add txnBot
status URL to ENVIRONMENT.md Common URLs section for consistency.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-17 07:07:31 +00:00
johba
9290975661 Merge pull request 'fix: fix: transpiler outputs raw int literals for uint24 anchorWidth — overflow crashes forge (#900)' (#903) from fix/issue-900 into master 2026-03-17 07:56:59 +01:00
openhands
1e75285579 fix: fix: transpiler outputs raw int literals for uint24 anchorWidth — overflow crashes forge (#900)
Clamp anchorWidth output with `% (2**24)` before the uint24 cast so that
large literal values (e.g. 1e18 from evolved constants) produce valid
Solidity instead of a compile-time overflow error.

Add test_transpiler_clamping.sh (Test 5) verifying that a Push3 program
outputting 1e18 for anchorWidth generates `uint24(... % (2**24))` and not
the raw overflowing literal. Update package.json to run both test suites.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-17 06:40:30 +00:00
johba
a2c60a29a0 Merge pull request 'fix: fix: batch-eval.sh aborts entire generation on single candidate compile failure (#901)' (#902) from fix/issue-901 into master 2026-03-17 07:29:14 +01:00
openhands
a23064f576 fix: batch-eval.sh aborts entire generation on single candidate compile failure (#901)
- Add skip_candidate() helper that emits fitness=0 JSON to stdout and
  tracks the failed score for the output-dir file, satisfying the
  downstream scorer's expectation of one JSON line per candidate.
- Unify all failure paths (transpile, forge build, bytecode extract,
  empty bytecode) through skip_candidate() with a distinct error key.
- Log message now reads "WARNING: <id> compile failed — scoring as 0"
  as required by the acceptance criteria.
- Output-dir scores.jsonl now merges successful + failed scores so the
  file is complete even when some candidates fail to compile.
- All-candidates-fail path (COMPILED_COUNT=0) still exits 2 (no viable
  population); true infra errors (missing tool, bad RPC) unchanged.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-17 06:09:18 +00:00
johba
f685f9a237 docs: add VISION.md — launch strategy and phase definitions (#894)
Three phases: quality gate → coordinated launch → operations.
Defines what "launched" means concretely for planner gap analysis.

From voice dump, distilled into actionable phases with concrete checkboxes.

Co-authored-by: openhands <openhands@all-hands.dev>
Reviewed-on: https://codeberg.org/johba/harb/pulls/894
Reviewed-by: review_bot <review_bot@noreply.codeberg.org>
2026-03-17 06:56:05 +01:00
johba
dbbbad99a5 Merge pull request 'fix: txnBot not covered by any phase documentation (#895)' (#896) from fix/issue-895 into master 2026-03-16 23:08:32 +01:00
openhands
2d942a8a24 ci: retrigger after infra failure 2026-03-16 21:43:51 +00:00
openhands
6a01d55ced fix: txnBot not covered by any phase documentation (#895) 2026-03-16 21:37:27 +00:00
johba
3ebec9cfaf Merge pull request 'fix: ARCHITECTURE.md omits conditional guard on feeDestination exclusion (#663)' (#890) from fix/issue-663 into master 2026-03-16 19:27:23 +01:00
openhands
dc2de3d470 fix: ARCHITECTURE.md omits conditional guard on feeDestination exclusion (#663) 2026-03-16 18:06:57 +00:00
johba
5e7918bfa8 Merge pull request 'fix: PRODUCT-TRUTH.md Fee Destination section omits the same conditional guard (#664)' (#888) from fix/issue-664 into master 2026-03-16 18:57:03 +01:00
openhands
ad56669fe3 fix: PRODUCT-TRUTH.md Fee Destination section omits the same conditional guard (#664) 2026-03-16 17:37:12 +00:00
johba
f88fa4bef8 Merge pull request 'fix: CodeDocs.vue shows stale recenter() with recenterAccess guard (#837)' (#885) from fix/issue-837 into master 2026-03-16 18:26:32 +01:00
openhands
65ffb51a64 fix: update _scrapePositions signature and body in CodeDocs.vue snippet (#837)
Update the embedded _scrapePositions definition to accept (bool recordVWAP,
int24 currentTick), compute currentPrice directly from the passed tick
instead of sampling the ANCHOR position's centre tick, remove the
ANCHOR-specific price-sampling branch from the loop, and replace the old
split fee+VWAP transfer logic with the current contract's structure:
feeDestination != address(this) guard before transfers, single ethFee
branch for VWAP recording.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-16 16:58:24 +00:00
openhands
076b25f4dd fix: CodeDocs.vue shows stale recenter() with recenterAccess guard (#837)
Remove the obsolete recenterAccess pattern from the liquidityManagerSol
snippet: drop the recenterAccess state variable, setRecenterAccess(),
revokeRecenterAccess(), and onlyFeeDestination modifier. Update recenter()
to reflect the current cooldown-only access model, fix the VWAP direction
logic, and update the _scrapePositions() call signature to match
LiquidityManager.sol.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-16 16:29:48 +00:00
johba
367dae31b8 Merge pull request 'fix: chore: fetch and cache Uniswap V3 replay datasets for evolution backtesting (#883)' (#884) from fix/issue-883 into master 2026-03-16 17:18:03 +01:00
openhands
fb83c70d23 fix: chore: fetch and cache Uniswap V3 replay datasets for evolution backtesting (#883)
- Add fetch-datasets.sh wrapper that fetches HIGHER/WETH, DEGEN/WETH,
  and TOSHI/WETH 30-day event caches via fetch-events.ts; reads
  INFURA_API_KEY from env and fails with a helpful error if unset
- Update .gitignore from cache/ (whole dir) to cache/*.jsonl so the
  pattern is precise to the generated data files; cache/ is already
  covered by the repo-root .gitignore via its own cache/ rule

JSONL cache files are gitignored and must be generated locally by
running ./fetch-datasets.sh with INFURA_API_KEY set.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-16 15:50:19 +00:00
johba
8733d17062 Merge pull request 'fix: SECURITY_REVIEW.md references obsolete recenterAccess pattern (#838)' (#880) from fix/issue-838 into master 2026-03-16 16:44:04 +01:00
openhands
10c90e4c50 fix: address AI review findings on SECURITY_REVIEW.md and deployment.md (#838)
- M-2: update body to show current deployer-only setFeeDestination()
  implementation and conditional locking; mark as partially resolved;
  downgrade severity from Medium to Low; update conclusion entry
- I-1: mark as resolved — Recentered event declared at line 66 and
  emitted at line 224 of LiquidityManager.sol
- I-2: correct VWAP direction (records on sells/ETH outflow, not buys);
  update stale line reference from 146-158 to 177-191
- deployment.md §6.5: replace vague 'assess severity' step 1 with
  concrete action (upgrade optimizer to bear defaults via §6.2)
- deployment.md §8 timeline: remove stale 'Set recenter access' row;
  update 'First recenter' dependency

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-16 15:15:33 +00:00
openhands
9b75817300 fix: SECURITY_REVIEW.md references obsolete recenterAccess pattern (#838)
- Update M-3 finding: recenterAccess was removed; MIN_RECENTER_INTERVAL
  (60s) cooldown now enforced unconditionally — downgrade severity to
  Informational (resolved)
- Update Access Control Summary: remove recenterAccess rows, reflect
  permissionless recenter() with cooldown
- Update Conclusion: mark M-3 as resolved
- Fix stale M-1 impact note that mentioned recenterAccess as a workaround
- deployment.md: remove Section 3.2 "Set Recenter Access" (setRecenterAccess
  no longer exists); update 3.3 first-recenter comment
- deployment.md: replace recenterAccess() verification call with
  lastRecenterTime() check
- deployment.md §6.1: rewrite Pause Recentering note — no access-control
  switch exists, cooldown is the only rate limiter
- deployment.md §6.5: remove stale setRecenterAccess(0xdEaD) instruction

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-16 14:43:37 +00:00
johba
ed15d23746 Merge pull request 'fix: fix: red-team cross-pattern export records intermediate states as DECREASED (#852)' (#876) from fix/issue-852 into master 2026-03-16 14:48:04 +01:00
openhands
f3fb1c3db0 fix: fix: red-team cross-pattern export records intermediate states as DECREASED (#852)
The extract_memory regex previously matched any "lm.?eth" mention,
including mid-execution "Total LM ETH: X wei" output lines produced by
the agent's cast check commands.  During a staking step these lines
reflect an intermediate chain state (ETH temporarily locked/moved)
rather than the final reverted state, causing strategies to be recorded
as DECREASED even when the runner confirmed ETH_SAFE.

Fix: narrow the capture to the structured `lm_eth_after: <value>`
label that the agent writes in its final RED-TEAM REPORT block.
Mid-execution total-ETH lines no longer match and cannot corrupt the
per-strategy result in memory or the cross-patterns file.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-16 13:19:03 +00:00
johba
da230b6c14 Merge pull request 'fix: feat: persist red-team cross-patterns in repo for continuity across runs (#853)' (#874) from fix/issue-853 into master 2026-03-16 14:08:24 +01:00
openhands
fe3a3d7d94 fix: feat: persist red-team cross-patterns in repo for continuity across runs (#853)
- Move CROSS_PATTERNS_FILE from /tmp/red-team-cross-patterns.jsonl to
  tools/red-team/cross-patterns.jsonl (repo-tracked path)
- Remove the reset (> file) at sweep start so patterns accumulate across runs
- Generate a SWEEP_ID (sweep-YYYYMMDD-HHMMSS) at sweep start and stamp
  each new entry with sweep_id for traceability
- Deduplicate on (pattern, candidate, result): entries already present in
  the file are skipped; intra-batch duplicates are also suppressed
- Create tools/red-team/ directory with .gitkeep
- Add mkdir -p guards in both scripts so the directory is created on first run

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-16 12:39:39 +00:00
johba
3d8bbb0975 Merge pull request 'fix: fix: red-team.sh V3_FACTORY hardcodes Base mainnet address instead of Sepolia (#854)' (#870) from fix/issue-854 into master 2026-03-16 13:26:05 +01:00
openhands
a2f89968db fix: fix: red-team.sh V3_FACTORY hardcodes Base mainnet address instead of Sepolia (#854)
bootstrap-light.sh now extracts the Uniswap V3 pool address from
DeployLocal.sol deploy output and writes both Pool and V3Factory
(Base Sepolia: 0x4752ba5DBc23f44D87826276BF6Fd6b1C372aD24) into
deployments-local.json alongside the existing contract addresses.

red-team.sh now reads V3_FACTORY and POOL from deployments-local.json
instead of hardcoding the Base mainnet factory address
(0x33128a8fC17869897dcE68Ed026d694621f6FDfD), and removes the getPool()
RPC call that always failed with "contract does not have any code" on
the Sepolia fork.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-16 12:02:17 +00:00
johba
740a871ddc Merge pull request 'fix: STATE.md #763 entry not removed after PR #773 merged (#776)' (#869) from fix/issue-776 into master 2026-03-16 11:37:21 +01:00
openhands
2e3cc6e641 fix: STATE.md #763 entry not removed after PR #773 merged (#776) 2026-03-16 10:17:01 +00:00
johba
c5519a34b1 Merge pull request 'fix: red-team-program.md taxRate naming inconsistency (pre-existing) (#835)' (#868) from fix/issue-835 into master 2026-03-16 11:14:20 +01:00
openhands
91e4bdf926 fix: red-team-program.md taxRate naming inconsistency (pre-existing) (#835) 2026-03-16 09:46:55 +00:00
johba
7e20f9fe74 Merge pull request 'fix: evolution.patch references removed LiquidityManager constant (pre-existing structural debt) (#842)' (#865) from fix/issue-842 into master 2026-03-16 10:36:08 +01:00
openhands
777bec8563 fix: evolution.patch references removed LiquidityManager constant (pre-existing structural debt) (#842)
Extend the patch to also replace the NatSpec comments above MAX_ANCHOR_WIDTH,
which became misleading after switching to type(uint24).max. The old comments
claimed overflow-safety ("fits in int24"); the new comments document that the
production cap is 1233, that values above 123358 overflow int24 and revert,
and that this is tolerable in the evolution context where reverts score zero
fitness. The patch now correctly updates both the constant and its documentation.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-16 09:20:41 +00:00
openhands
c0fa8c064f fix: evolution.patch references removed LiquidityManager constant (pre-existing structural debt) (#842)
Regenerate evolution.patch from the current ThreePositionStrategy.sol.
The old patch had a corrupt hunk header (@@ -33,7 +33,7 @@ claiming 7 lines
but only supplying 4) and placeholder index hashes (0000000..0000000),
causing `git apply` to reject it with "corrupt patch". MAX_ANCHOR_WIDTH
still exists in the file at value 1233; the patch correctly overrides it
to type(uint24).max for unbounded evolution runs.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-16 08:53:33 +00:00
johba
8c825589e2 Merge pull request 'fix: MEMORY_FILE parent directory ($REPO_ROOT/tmp/) also not guaranteed to exist (#844)' (#863) from fix/issue-844 into master 2026-03-16 09:36:59 +01:00