EIP-1967 · Upgrade safety

Slotlens — what your upgrade actually overwrites

A proxy upgrade swaps the code and keeps the storage. If V2 lays its variables out differently than V1, the new code reads the old bytes and interprets them as something else. Solidity will not warn you. Paste two storage layouts and see the collision at byte resolution.

No network access — enforced by Content-Security-Policy, not by promise

Findings
Slot map · V1 above, V2 below
SLOT byte 31 — most significantbyte 0 — offset 0
Check your own contracts

Generate the JSON with forge inspect MyContractV1 storageLayout or solc --storage-layout. Both emit the { storage, types } object this expects.

EIP-1967 reserved slots — checked on every run
Implementation pointer0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc
Admin pointer0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103
Beacon pointer0xa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d50

Each is keccak256(id) − 1, chosen so no sequentially allocated variable can land there. An implementation only reaches these slots through inline assembly — which is exactly the case worth catching.