From 2c6132c7222d20ca6f16aaa7792b0fc511a228a7 Mon Sep 17 00:00:00 2001 From: Kevin Ingersoll Date: Mon, 29 Jul 2024 15:49:04 +0100 Subject: [PATCH 1/4] fix(store): don't deploy codegen-only table --- packages/store/mud.config.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/store/mud.config.ts b/packages/store/mud.config.ts index f42f338267..fdcee6766a 100644 --- a/packages/store/mud.config.ts +++ b/packages/store/mud.config.ts @@ -36,7 +36,7 @@ export default defineStore({ }, key: ["resourceId"], }, - // The Hooks table is a generic table used by the `filterFromList` util in `Hook.sol` + // This is generic, codegen-only table used by `filterFromList` in `Hook.sol` Hooks: { schema: { resourceId: "ResourceId", @@ -46,6 +46,9 @@ export default defineStore({ codegen: { tableIdArgument: true, }, + deploy: { + disabled: true, + }, }, }, }); From f88734f9435d229bef893529d6115d5deecf1d31 Mon Sep 17 00:00:00 2001 From: Kevin Ingersoll Date: Mon, 29 Jul 2024 15:50:58 +0100 Subject: [PATCH 2/4] don't deploy disabled tables --- packages/cli/src/runDeploy.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/cli/src/runDeploy.ts b/packages/cli/src/runDeploy.ts index 1bf116e10e..36e63e5505 100644 --- a/packages/cli/src/runDeploy.ts +++ b/packages/cli/src/runDeploy.ts @@ -129,7 +129,9 @@ export async function runDeploy(opts: DeployOptions): Promise { console.log("Deploying from", client.account.address); - const tables = Object.values(config.namespaces).flatMap((namespace) => Object.values(namespace.tables)); + const tables = Object.values(config.namespaces) + .flatMap((namespace) => Object.values(namespace.tables)) + .filter((table) => !table.deploy.disabled); const startTime = Date.now(); const worldDeploy = await deploy({ From f16a56dfac914fd6c3bb18dd8c58bcfed1a43107 Mon Sep 17 00:00:00 2001 From: Kevin Ingersoll Date: Mon, 29 Jul 2024 07:55:26 -0700 Subject: [PATCH 3/4] Create new-ways-count.md --- .changeset/new-ways-count.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .changeset/new-ways-count.md diff --git a/.changeset/new-ways-count.md b/.changeset/new-ways-count.md new file mode 100644 index 0000000000..b4d2d23408 --- /dev/null +++ b/.changeset/new-ways-count.md @@ -0,0 +1,5 @@ +--- +"@latticexyz/cli": patch +--- + +`mud deploy` will now correctly skip tables configured with `deploy: { disabled: true }`. From 26313ee951f96d873fdfeaa43592d0b589a5329f Mon Sep 17 00:00:00 2001 From: Kevin Ingersoll Date: Mon, 29 Jul 2024 07:56:11 -0700 Subject: [PATCH 4/4] Create chilly-horses-accept.md --- .changeset/chilly-horses-accept.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .changeset/chilly-horses-accept.md diff --git a/.changeset/chilly-horses-accept.md b/.changeset/chilly-horses-accept.md new file mode 100644 index 0000000000..e011d7cf25 --- /dev/null +++ b/.changeset/chilly-horses-accept.md @@ -0,0 +1,5 @@ +--- +"@latticexyz/store": patch +--- + +Disabled deploy of `Hooks` table, as this was meant to be a generic, codegen-only table.