feat: DogeOS-minimal local stack for integration testing#61
Draft
vmarkushin wants to merge 6 commits intodogeosfrom
Draft
feat: DogeOS-minimal local stack for integration testing#61vmarkushin wants to merge 6 commits intodogeosfrom
vmarkushin wants to merge 6 commits intodogeosfrom
Conversation
Adds a local development stack that runs Anvil (L1), L2 geth, Dogecoin regtest, and l1-interface without Kubernetes. Full deposit pipeline proven end-to-end: Dogecoin → l1-interface → L2 geth → Moat contract. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Auto-detects regtest via getblockchaininfo and uses importaddress+ listunspent/getrawtransaction/sendrawtransaction instead of Electrs/Blockbook. Fully backward-compatible — testnet/mainnet callers are unaffected. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- setupRegtest(): auto-funds master address from regtest coinbase - waitForConfirmations: auto-mines blocks on regtest so txs confirm - mineRegtestFinality(): mines blocks for l1-interface deposit finality - Bridge address defaults to known value on regtest - Export dogeRpc for direct Dogecoin RPC calls Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Remove agent-handoff and testing_improvements docs from PR - Anvil only starts for Phase 1/2 (contract deployment), not Phase 3 - Add comments explaining L1 contract deployment is for address generation - Add removed docs to .gitignore Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…test Dogecoin regtest uses Bitcoin testnet prefixes (pubKeyHash 0x6f, WIF 0xEF) unlike Dogecoin testnet (0x71, 0xF1). This caused "Invalid Dogecoin address" errors when the test command tried to use testnet-encoded addresses on regtest. - Add dogecoinRegtest network definition with correct prefixes - Auto-switch to regtest network when direct RPC is detected - Cross-decode WIF keys (testnet WIF works on regtest via private key extraction) - Store decoded masterKeyPair as instance variable (avoids repeated WIF decoding) - Relax UTXO confirmation filter on regtest (>= 1 instead of > 1) - Mine 6 blocks after funding to ensure UTXOs are immediately spendable Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…tSpec Add L1InterfaceConfig and DaPublisherConfig types to DeploymentSpec so l1-interface and da-publisher configs are generated from a single source of truth instead of hand-maintained static files. The generator writes to .data/ alongside doge-config.toml; start.sh falls back to the old local-stack/ paths for backward compatibility. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
local-stack/) that runs Dogecoin regtest + l1-interface + L2 geth for integration testing without Kubernetestest dogeoswith a direct Dogecoin RPC backend that auto-detects regtest and bypasses Electrs/Blockbook — fully backward-compatible with existing testnet/mainnet usageDetails
Local stack (
local-stack/)start.sh/stop.sh— orchestration scripts that bring up Dogecoin regtest, l1-interface, and L2 gethdeploy-contracts.sh— optional Anvil-based bridge contract deployment (Phase 1/2 only; Phase 3 skips Anvil)test dogeosimprovementsDogeRpcConfiginterface +dogeRpc()helper indogeos-utils.tsgetUtxos,getTx,broadcastTx,waitForConfirmationsaccept optionalrpcConfig— when provided, use direct Dogecoin RPC instead of Electrs/BlockbookwaitForConfirmationsauto-mines 1 block per poll on regtestsetupRegtest()— auto-funds master address from coinbase if balance < 1000 DOGEmineRegtestFinality()— mines 200 blocks for l1-interface deposit finalitydogecoinRegtestnetwork definition — Dogecoin regtest uses Bitcoin testnet address/WIF prefixes (0x6f/0xEF), not Dogecoin testnet ones (0x71/0xF1)Backward compatibility
All new parameters are optional. Existing testnet/mainnet users see zero behavior change — no new dependencies, no config changes required.
Test plan
yarn buildpassesyarn lintpasses (0 errors, only pre-existing complexity warnings)local-stack/start.shand verify Dogecoin regtest + L2 geth come up./bin/run.js test dogeos 1against local stack — Case 1 (Multiple OP_RETURN) passes./bin/run.js test dogeos 2against local stack — Case 2 (Multiple Output) passes./bin/run.js test dogeos 3against local stack — Case 3 (Bridge UTXO Attack) broadcasts 100/100 txs, Dogecoin side passes. L2 deposit verification requires full l1-interface pipeline processing time../bin/run.js test dogeosagainst testnet — verify no regression🤖 Generated with Claude Code