Skip to content

Show initialized storage values immediately after deploy - #2

Merged
halaprix merged 1 commit into
masterfrom
feat/deploy-trace-initializers
Jul 29, 2026
Merged

Show initialized storage values immediately after deploy#2
halaprix merged 1 commit into
masterfrom
feat/deploy-trace-initializers

Conversation

@halaprix

Copy link
Copy Markdown
Owner

What

Constructor writes (e.g. uint256 x = 42;) were completely invisible after "Deploy locally" — deploy never captured a trace, so the only way to see an initialized value was to make an explicit call first.

Fix

The constructor is an execution like any other. handleDeploy now requests captureTrace: true exactly like handleCall does, and the result runs through the identical resolveAccesses pipeline (depth-0 resolvable steps — inherited base-constructor writes run in the same top-level frame, not a nested CALL, so they resolve correctly too).

Runtime storage now shows the constructor's writes labeled "from the constructor" immediately after a successful deploy, with real resolved labels and decoded byte values — no source parsing, no heuristics, purely what the constructor measurably wrote. A zero-valued initializer needs no SSTORE (storage is already zero by default) and honestly shows nothing.

Also fixed: a redeploy now unconditionally clears the previous trace before running, so a constructor with no writes of its own doesn't leave a stale trace from an earlier deployment lingering on screen.

Changelog

Added the 1.1.0 entry — this feature plus the already-merged post-launch UX pass (Variant B cockpit workbench, live storage strip, design-sync-v2 grid, reserved-hue review fixes) that had landed on master without a version bump.

Verification

  • New e2e test: deploys a contract with a non-zero uint256, a non-zero bool, and an untouched (zero) uint256; asserts the first two appear in Runtime storage with correct decoded values and the zero one does not; also checks the Trace tab labels itself DEPLOY · constructor.
  • 209 unit + 58 e2e green (full suite, including the new test)
  • lint, format, typecheck, build, build:check, fixtures:verify, deps:policy, token-discipline — all clean

🤖 Generated with Claude Code

Constructor writes (e.g. `uint256 x = 42;`) were completely invisible
after "Deploy locally" — deploy never captured a trace, so the only
place a value could appear was after an explicit call.

The honest fix: the constructor is an execution like any other. Deploy
now captures its trace exactly like a call (captureTrace: true), runs
it through the same resolveAccesses pipeline (depth-0 resolvable steps,
so inherited-base-constructor writes resolve correctly too — they run
in the same top-level frame, not a nested CALL), and Runtime storage
shows the result labeled "from the constructor". No source parsing, no
heuristics — purely what the constructor measurably wrote. A
zero-valued initializer needs no SSTORE (storage is already zero) and
honestly shows nothing.

Also: a redeploy now unconditionally clears the previous trace before
running, so a constructor with no writes doesn't leave a stale trace
from an earlier deployment on screen.

CHANGELOG: adds the 1.1.0 entry for this plus the already-shipped
post-launch UX pass (Variant B cockpit workbench, live storage strip,
design-sync-v2 grid, reserved-hue review fixes) that had landed on
master without a version bump.

Closes: slotscope-p1t

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@halaprix
halaprix merged commit 1918f05 into master Jul 29, 2026
6 checks passed
@halaprix
halaprix deleted the feat/deploy-trace-initializers branch July 29, 2026 09:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant