feat(revive): v0.0.39 — pallet-revive wired runtime Index 11 (22 Config types + GenesisConfig + WASM rebuild) 🎉🎉

Ship 2 v0.0.39 SHIPPED — pallet-revive 0.10.1 integration end-to-end post
Ship 1.5 v0.0.38 workspace bump stable2509-3 atómico. SBS-5 ratificado
(supersedes CHN-6 v1.0): smart contracts PolkaVM RISC-V + ink! v6 + Solidity
deployables canonical post Slice 3.1 SCAFFOLD COMPLETE pending Ship 3+4
(v0.0.40 integration tests + v0.0.41 ReviveApi).

Cambios:
- Cargo.toml workspace.dependencies: pallet-revive 0.10.1 crates.io
  (NOT git source — git source pulled duplicate frame-system/sp-runtime copies
  rompiendo trait bounds canonical. Crates.io 0.10.1 deps match workspace
  bumped stable2509-3 generation clean canonical empírico).
- crates/origin-chain-runtime/Cargo.toml: pallet-revive added dep + features.std.
- crates/origin-chain-runtime/src/lib.rs: Runtime macro Index 11 added
  `pub type Revive = pallet_revive::Pallet<Runtime>` canonical.
- crates/origin-chain-runtime/src/configs.rs: pallet_revive::Config impl con
  22 associated types per pallet-revive 0.10.1 docs.rs canonical surface:
  * Runtime types: RuntimeEvent, RuntimeCall, RuntimeHoldReason
  * Currency/Balance: Currency=Balances, Time=Timestamp, WeightPrice=TransactionPayment
  * Storage/Deposit: DepositPerByte=MILLI_OGC, DepositPerItem=OGC,
    CodeHashLockupDepositPercent=30%
  * EVM/Mapping: AddressMapper=AccountId32Mapper, ChainId=9_120_005 (EIP-155
    unique Origin Metaverse), NativeToEthRatio=1_000_000 (OGC 12 dec → ETH 18),
    AllowEVMBytecode=true, EthGasEncoder=()
  * Precompiles=() Slice 3.1 SCAFFOLD interim
  * Limits: WeightInfo=SubstrateWeight, RuntimeMemory=128 MB, PVFMemory=2 GB
    (per integrity_test formula `storage_limit = (PVFMemory-RuntimeMemory)/2`
    needed PVFMemory > 1.5 GB para pass max_storage_size ~650 MB check)
  * Access Control: UploadOrigin=EnsureSigned, InstantiateOrigin=EnsureSigned
  * Safety: FindAuthor=() (no pallet_authorship), UnsafeUnstableInterface=false
- crates/origin-chain-runtime/src/genesis_config_presets.rs: ReviveConfig::default()
  added a build_genesis canonical (Slice 3.1 SCAFFOLD: no pre-mapped accounts,
  no genesis contracts — Phase 3.x maduración añade dev mapped_accounts +
  templates contracts Slices 3.2-3.6).

API diffs encontrados empírico pallet-revive 0.10.1 vs 0.12.2 audit inicial:
- 0.10.1 NO expone: RuntimeOrigin, DebugEnabled, FeeInfo, MaxEthExtrinsicWeight,
  GasScale, DepositPerChildTrieItem (todos added en 0.12+ Asset Hub generation).
- 0.10.1 SÍ require: WeightPrice (Convert<Weight, Balance>) + EthGasEncoder
  (gas conversion helper) — NO en 0.12.2 audit anterior.

Verificación:
- cargo check --workspace clean (warnings pre-existentes deprecated patterns)
- cargo test --workspace: 203 tests verde 0 failures NO regresiones
- cargo build --features wasm-build: WASM_BINARY 2.8 MB shipped clean
  (grew from 1.8 MB v0.0.36 baseline — +1 MB pallet-revive PolkaVM bytecode)
- Runtime integrity test (__construct_runtime_integrity_test) PASS post memory
  tuning empírico-validated (16/16 runtime tests verde).

Próximo Ship 3 v0.0.40: pallet-revive real impl + 10 integration tests E2E
(upload_code + instantiate + bare_call + storage deposit + AddressMapper +
gas metering + access control + ChainId EIP-155 + contract destruction).

⚓ Phase 3 Slice 3.1 Ship 2/4 SHIPPED. La nave entra zone canonical smart contracts.

🤖 Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
davidherran committed 2026-05-27 08:36:24 -05:00
1 parent ebe09f1b2e
commit 86d9251908
6 files changed
+2401 -49

No files matched your search

+13 -5
View File
@@ -83,12 +83,20 @@ pallet-session = { version = "43.0.0", default-features = false }
# ============================================================
# Phase 3 — pallet-revive smart contracts per SBS-5 ratified
# (supersedes CHN-6 v1.0 → CHN-6 v2.0 PolkaVM + ink! v6 + Solidity)
# Version pin: 0.12.2 (canonical para stable2512-3, verified vía
# github.com/paritytech/polkadot-sdk/blob/polkadot-stable2512-3/substrate/frame/revive/Cargo.toml).
# Bump a 0.17.0 scope Phase 8+ (post-mainnet Substrate generation upgrade).
#
# **Critical version decision (Ship 2 v0.0.39 audit empirical refinement)**:
# Git source pin pulls duplicate copies de frame-system/sp-runtime canonical
# (cargo trata git source + crates.io como crates distintos). Switch a crates.io
# 0.10.1 published version post Ship 1.5 v0.0.38 workspace bump empírico —
# bumped substrate generation pulls newer transitive deps clean per cargo
# resolver canonical. pallet-revive 0.10.1 was pkg de polkadot-stable2509-3
# release tag, deps match my bumped workspace stable2509-3 pin generation.
# ============================================================
pallet-revive = { version = "0.12.2", default-features = false }
pallet-revive-uapi = { version = "0.13.0", default-features = false, features = ["scale"] }
pallet-revive = { version = "0.10.1", default-features = false }
# pallet-revive entry CONSOLIDATED arriba (línea 92) — Ship 1 v0.0.37 puro
# crates.io 0.12.2 deprecated post Ship 1.5 v0.0.38 workspace bump + Ship 2
# v0.0.39 git source canonical polkadot-stable2509-3 tag (0.10.1 matched generation).
# pallet-identity DEFERRED a Phase 2.7 — canonical decision empírica 2026-05-21:
# pallet-identity 41.0.0 usa ReservableCurrency trait (deprecated en stable2512,