v0.20.0
One theme: the wallet now drives Vara.eth as a first-class chain. The substrate rail (vara-wallet --chain vara) is untouched. A parallel vara-wallet --chain vara-eth rail ships with read paths verified on mainnet + Hoodi, L1 write path verified on Hoodi, and an injected-tx persistence layer that survives kill/restart for terminal outcomes. Typed errors from @vara-eth/api@0.5.0-rc.1 now surface as MESSAGE_REVERTED / PROMISE_TIMEOUT / CHAIN_ID_MISMATCH (etc.) directly in JSON output. Diagnostics flag --no-validate-signature lets operators bypass the validator-signature check on injected-path replies when triaging recovery failures.
Added — Vara.eth rail
Adds a parallel command tree for the Vara.eth co-processor on Ethereum so the same CLI now drives both native Vara and Vara.eth. Substrate commands are untouched. Vara.eth commands live under the vara-eth: prefix, and root commands route through Vara.eth when --chain vara-eth is set.
- Wallet management (
vara-eth:wallet create|import|list|show|keys). New~/.vara-wallet/wallets/<name>.vara-eth.jsonfiles in standard Ethereum V3 keystore format (scrypt + AES-128-CTR), MetaMask / ethers / web3.js interoperable. Keys derive at BIP44 pathm/44'/60'/0'/0/0from a generated 12-word BIP39 mnemonic, or from--mnemonic/--private-keyon import. Files are written 0o600. - Messaging (
vara-eth:message send|reply).sendsupports the injected-transaction path (signed off-chain, dispatched through a validator) and the direct L1 path via--via eth.replygoes throughMirror.sendReply. - Program lifecycle (
vara-eth:program deploy|top-upplus rootprogram upload|deploy|top-upunder--chain vara-eth). Deploy runs the combined upload + create ceremony viaapi.programs.deploy. - State inspection (
vara-eth:state read) and rootstate readunder--chain vara-eth. - Mailbox (
vara-eth:mailbox claim). Claims a value entry byclaimedId. - Event streams (
vara-eth:subscribe program|router|blocks). Emits NDJSON to stdout until SIGINT/SIGTERM. - Phase 3b operations (
vara-eth:wvara *,vara-eth:inheritor recover,vara-eth:validators *) are implemented for wallet-side flows.
Added — supporting infrastructure
- Chain dispatch at
src/chains/types.ts(Chain = 'vara' | 'vara-eth',resolveChain()with precedence--chain>config.defaultChain>'vara'). - Wallet-side error taxonomy at
src/shared/errors-eth/(KeystoreDecryptError,WrongPassphraseError,UnsupportedChainOperationError). Lib-side typed errors stay in@vara-eth/apito preserve its adapter shape. - Shared CLI argument validators at
src/utils/eth-types.ts(asAddress,asHex,parseOptionalBigInt) backed by viem'sisAddress/isHex. - Config (
src/services/config.ts) extended withdefaultChain,varaEthRpc,ethereumRpc,routerAddressfields. All optional; env vars (VARA_ETH_RPC,ETHEREUM_RPC,VARA_ETH_ROUTER) take precedence.
Changed
- Node engine bumped to
>=22(already invs/node-22-bump). Matches@vara-eth/api's engine requirement. - esbuild bundle externalises the cryptographic + ESM-only deps (
@noble/ciphers,@noble/curves,@noble/hashes,@scure/bip32,@scure/bip39,viem,kzg-wasm,@vara-eth/api) so Node's runtime resolution picks the right CJS/ESM variant. Without this, esbuild followed the ESMexports.importpath ofkzg-wasmwhich usesimport.meta.urland crashes in a CJS bundle. - jest configured to transform
@noble/*and@scure/*ESM sources via ts-jest, and to stub@vara-eth/api(src/__tests__/fixtures/vara-eth-api.stub.ts) so unit tests don't drag the full viem + kzg-wasm tree into ts-jest.
Dependencies
- Adds:
@noble/ciphers,@noble/curves,@noble/hashes,@scure/bip32,@scure/bip39,kzg-wasm,viem(aliased to@vara-eth/viem@2.48.11fork for EIP-7594 blob support), and@vara-eth/api(currentlyfile:vendor/vara-eth-api-0.5.0-rc.1.tgzuntil the public npm publish).
Added — Milestone A + B (production-readiness)
- Global
--account/--passphrasepropagate into everyvara-eth:*subcommand. Substrate parity: pass the flag at the root command (vara-wallet --account alice vara-eth:wvara approve …) and the action handler picks it up viacmd.optsWithGlobals(). Previously the global was silently ignored and the resolver fell through toconfig.defaultAccount. Also adds--passphraseto the root command (Vara.eth keystores only; substrate side still readsVARA_PASSPHRASEenv /.passphrasefile). - ReplyCode JSON output now emits
{ tag, raw, reason }(e.g.{ tag: "Success.Auto", raw: "0x00000000", reason: "Success reply was created by system automatically." }). The wallet extracts the tag through the existingis*getters. Lossless:rawis the underlying 4-byte hex. MessageRevertedErrorflows from@vara-eth/api@0.5.0-rc.1throughformatErrorto JSON output as{ code: 'MESSAGE_REVERTED', error, reason, functionName }. Contract reverts (e.g.InitMessageNotCreatedAndCallerNotInitializer()) now carry their decoded selector + the entry point that failed, so agents can branch oncode === 'MESSAGE_REVERTED'instead of regex-matchingerror.message.--no-validate-signatureflag onvara-eth:message sendfor diagnostics. PassesvalidateSignature: falseto the lib'ssendAndWait, skipping the validator-signature recovery check on injected-path replies. Useful only for triaging signature-mismatch failures (currently surfacing on Hoodi). Production default remainstrue.
Added — bridged VFT token aliases (from main)
- Built-in bridged VFT token aliases. New
token list/token resolvecommands expose official Vara bridge token program IDs for mainnet/testnet. Existingvftanddextoken arguments now accept aliases likeusdc,wusdc,weth,wbtc,tokenized-vara,wvara, andwtvarawhile preserving raw token program address support.
Changed — native query path performance
- Lower-overhead Sails, VFT, and DEX lookup helpers. Method suggestions now reuse one deduped candidate list, Sails event-name resolution scans inherited services once per lookup, built-in token aliases resolve through a precomputed network-aware map,
vft inforuns independent per-field fallback chains in parallel, anddex pairsqueries each repeated token symbol once before mapping symbols back to the original pair order.
Changed — Vara.eth chain token (breaking on this branch only — no prior release)
- Chain token renamed
ethexe→vara-etheverywhere user-visible: CLI flag (--chain vara-eth), command prefix (vara-eth:*), wallet file suffix (.vara-eth.json), config key (defaultChain: 'vara-eth'). No legacy shims — this branch never shipped to users with the old token. Internal types:Chain = 'vara' | 'vara-eth'.
Tests
- 25 new unit tests in Phase 3a (V3 keystore, BIP39 + BIP32 HD, chain resolution, wallet-store migration).
- 14 net-new unit tests in Milestone A (
vara-eth-opts-globals.test.ts× 4,reply-code-serializer.test.ts× 10). - 3 net-new unit tests in Milestone B (
vara-eth-error-mapping.test.ts). - 4 net-new unit tests in the lib (
@vara-eth/api,message-reverted.test.ts). - Focused native-query regression coverage for token alias lookup, VFT info fallback behavior, and DEX pair symbol deduplication.
- Total wallet suite: 839 passing.
Verified end-to-end (Hoodi)
- Three real on-chain transactions through
vara-eth:message send --via ethagainst deployed one-of-us Mirrors. Seedocs/vara-eth-integration-report.md§2.2 for tx hashes. - Read path against both Hoodi and Vara.eth mainnet (Router + WVARA balanceOf, Mirror state reads). See
docs/vara-eth-integration-report.md§2.1.