Skip to content

Commit 3f6abeb

Browse files
cha0sg0dalvrs
andauthored
fix(cli): mud trace bug for non-local networks (latticexyz#276)
* feat: allow mud trace on non-local networks * build: don't attempt to publish docs for fork prs Co-authored-by: alvrs <[email protected]>
1 parent 60d4ae8 commit 3f6abeb

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

.github/workflows/docs.yml

+1
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ jobs:
3939
run: yarn docs
4040

4141
- name: Publish to Cloudflare Pages
42+
if: github.event.pull_request.head.repo.full_name == github.repository
4243
id: cloudflare_publish
4344
uses: cloudflare/pages-action@13c6a2f35417aaf1906cdbb1f6faf6c72c697b08
4445
with:

packages/cli/src/commands/trace.ts

+4-2
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ export const handler = async (argv: Arguments<Options>): Promise<void> => {
3131
const deployData = config && JSON.parse(readFileSync(config, { encoding: "utf8" }));
3232
const labels = [];
3333

34-
const provider = new JsonRpcProvider(rpc || "http://localhost:8545");
34+
const rpcUrl = rpc || "http://localhost:8545";
35+
const provider = new JsonRpcProvider(rpcUrl);
3536
const World = new Contract(world, WorldAbi, provider);
3637

3738
if (deployData) {
@@ -57,11 +58,12 @@ export const handler = async (argv: Arguments<Options>): Promise<void> => {
5758

5859
labels.push(...components, ...systems);
5960
}
60-
6161
await execLog("cast", [
6262
"run",
6363
...labels.map((label) => ["--label", `${label[1]}:${label[0]}`]).flat(),
6464
...(debug ? ["--debug"] : []),
65+
`--rpc-url`,
66+
`${rpcUrl}`,
6567
`${tx}`,
6668
]);
6769

0 commit comments

Comments
 (0)