-
Notifications
You must be signed in to change notification settings - Fork 886
test(inprocess): migrate authz + wasm + flatkv_evm + seidb; de-flake distribution #3721
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: feat/inprocess-migrations-batch2
Are you sure you want to change the base?
Changes from all commits
5c32129
e688bad
fc786aa
317c690
dd35a0c
54c3999
718000e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -5,6 +5,11 @@ const crypto = require("crypto"); | |
|
|
||
| const adminKeyName = "admin" | ||
|
|
||
| // SEI_EVM_RPC (set by the in-process runner) points `seid tx evm` eth-submitting | ||
| // commands at the node's dynamic EVM endpoint. Unset under docker → empty, so the | ||
| // CLI's in-container :8545 default stands and the docker commands are byte-identical. | ||
| const evmRpcFlag = process.env.SEI_EVM_RPC ? ` --evm-rpc ${process.env.SEI_EVM_RPC}` : "" | ||
|
|
||
| const ABI = { | ||
| ERC20: [ | ||
| "function name() view returns (string)", | ||
|
Comment on lines
5
to
15
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🟡 The new Extended reasoning...What the bug isThe PR introduces Code path
Why existing safeguards do not catch it
Step-by-step proof
ImpactLocal-dev-only footgun. CI never has both a docker cluster and the inprocess job in the same runner, so this doesn't affect the PR's green build. The failure is loud (hang / clear connection error), not silent data corruption, and the workaround ( How to fixAdd a one-liner at the top of async function isDocker() {
if (process.env.SEI_IN_PROCESS) return false;
return new Promise((resolve, reject) => {
exec("docker ps --filter 'name=sei-node-0' --format '{{.Names}}'", ...);
});
}This makes the in-process signal |
||
|
|
@@ -142,7 +147,7 @@ async function evmSend(addr, fromKey, amount="10000000000000000000000000") { | |
| // seid tx evm send prints "Transaction hash: 0x..." on its own format | ||
| // (not the standard cosmos JSON response), so we extract from text and | ||
| // wait via the JSON-RPC receipt — semantically equivalent to -b block. | ||
| const output = await execute(`seid tx evm send ${addr} ${amount} --from ${fromKey} -b sync -y`); | ||
| const output = await execute(`seid tx evm send ${addr} ${amount} --from ${fromKey} -b sync -y${evmRpcFlag}`); | ||
| const evmTxHash = output.replace(/.*0x/, "0x").trim() | ||
| await waitForReceipt(evmTxHash) | ||
| return evmTxHash | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -207,7 +207,7 @@ if [ -z "$deploy_tx" ]; then | |
| fi | ||
| deploy_receipt=$(wait_for_receipt "$deploy_tx") | ||
| require_success_receipt "contract deployment" "$deploy_receipt" | ||
| printf "%s\n" "$deploy_receipt" > "$out_dir/flatkv_evm_deploy_receipt.json" | ||
| printf "%s\n" "$deploy_receipt" > /tmp/flatkv_evm_deploy_receipt.json | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [nit] This debug receipt is now written to a fixed There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [nit] This redirect was changed from |
||
|
|
||
| contract_addr=$(printf "%s\n" "$deploy_receipt" | jq -r '.result.contractAddress // empty') | ||
| if [ -z "$contract_addr" ] || [ "$contract_addr" = "null" ]; then | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
EVM RPC flag partially wired
Medium Severity
The in-process runner sets
SEI_EVM_RPCto the node’s dynamic EVM endpoint, and this change addsevmRpcFlagfor that purpose, but onlyevmSenduses it.associateKey,associateKeyStrict, andassociateWasmstill invokeseid tx evmwithout--evm-rpc, so those calls keep the CLI’s default:8545while Hardhat uses the repointed RPC.Additional Locations (2)
contracts/test/lib.js#L277-L289contracts/test/lib.js#L932-L934Reviewed by Cursor Bugbot for commit 718000e. Configure here.