Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

BL-33: On-chain deployment drift check — verify foundry/deployments/<network>.json still matches the chain

Aperta
#244 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@robertocarlous ci sta già lavorando.

Dal 15/10/2026.

  • #254 di @robertocarlous — aperta

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
35/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
python, solidity

Direzione di ricerca

Read foundry/deployments/<network>.json, dincli/cli/system.py around import_deployments, and Developer/BACK_LOG.md BL-33 to understand the deployment records. Then inspect the Foundry scripts and contract interfaces for the listed proxy slots, ownership, wiring, and slasher checks. Done means a read-only verifier reports expected and actual values for each recorded contract and exits non-zero on any drift.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Approved enhancement

Summary

Nothing currently verifies that foundry/deployments/<network>.json (and the din_info that dincli system import-deployments writes) still matches what is actually deployed. A fresh clone, a failed upgrade, or a manual intervention can leave the recorded addresses and the chain out of sync with no visible signal.

Proposal

A read-only check — either a forge script (script/VerifyDeployment.s.sol) or a new dincli system verify-deployment subcommand — that for each contract recorded in the deployments JSON reports OK or DRIFT with expected vs. actual values for:

  1. Proxy implementation slot — read EIP-1967 bytes32(uint256(keccak256("eip1967.proxy.implementation")) - 1) and compare against the recorded implementation address.
  2. Proxy admin slot — read EIP-1967 bytes32(uint256(keccak256("eip1967.proxy.admin")) - 1) and compare against the recorded proxyAdmin* address.
  3. Runtime code hash — keccak256(extcode(implementation)) vs. keccak256 of the current forge build artifact's deployedBytecode (immutables masked out via forge inspect --json).
  4. Owner / DIN-Representative addresses — call owner() on each ownable contract and compare.
  5. Wiring — DinCoordinator ↔ DinToken / DinValidatorStake / DinModelRegistry / fee router / treasury links, and slasher authorizations on DinValidatorStake.

Exit non-zero on any DRIFT row.

When to run

  • Before every DevNet 3.0 deploy.
  • After every UpgradePlatform.s.sol run.
  • As an optional CI step on pushes that touch foundry/script/.

Limitations

This check only covers what the deployments JSON records. A clean run does not prove nothing else was deployed or authorized outside that file.

References

  • Developer/BACK_LOG.md BL-33
  • foundry/deployments/ (network JSON files)
  • dincli/cli/system.py import_deployments — the import side that reads the same JSON
  • Terraform state-vs-live drift pattern (Osomudeya/devops-scripting-labs 03-drift-detection, reviewed 2026-10-02)
Lingua principale
Python
Stelle
4
Fork
7
Merge medio
3g 4h
PR unite (30g)
34

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di InfiniteZeroFoundation/DevNet

Tutte le issue di InfiniteZeroFoundation/DevNet

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.