-
Notifications
You must be signed in to change notification settings - Fork 60
Open
Description
Following the docs https://docs.inkathon.xyz/, I tried to create a fresh project with:
bun x create-inkathon-app@latest
but the generator fails during bun install with the following output:
✔ Repository cloned successfully
✔ Repository cleaned up successfully
✔ Project files updated successfully
✖ Failed to install dependencies
✖ Command failed: bun install
Resolving dependencies
Resolved, downloaded and extracted [0]
node:fs:1739
const stats = binding.stat(
^
Error: ENOENT: no such file or directory, stat '/Users/alexbean/Documents/frontends/my-inkathon-app/node_modules/.bun/[email protected]/package.json'
at Object.statSync (node:fs:1739:25)
at _getPackageJson (/Users/alexbean/Documents/frontends/my-inkathon-app/node_modules/.bun/[email protected]/node_modules/simple-git-hooks/simple-git-hooks.js:232:13)
at checkSimpleGitHooksInDependencies (/Users/alexbean/Documents/frontends/my-inkathon-app/node_modules/.bun/[email protected]/node_modules/simple-git-hooks/simple-git-hooks.js:129:34)
at postinstall (/Users/alexbean/Documents/frontends/my-inkathon-app/node_modules/.bun/[email protected]/node_modules/simple-git-hooks/postinstall.js:15:9)
at Object.<anonymous> (/Users/alexbean/Documents/frontends/my-inkathon-app/node_modules/.bun/[email protected]/node_modules/simple-git-hooks/postinstall.js:23:1)
at Module._compile (node:internal/modules/cjs/loader:1688:14)
at Object..js (node:internal/modules/cjs/loader:1820:10)
at Module.load (node:internal/modules/cjs/loader:1423:32)
at Function._load (node:internal/modules/cjs/loader:1246:12)
at TracingChannel.traceSync (node:diagnostics_channel:322:14) {
errno: -2,
code: 'ENOENT',
syscall: 'stat',
path: '/Users/alexbean/Documents/frontends/my-inkathon-app/node_modules/.bun/[email protected]/package.json'
}
Node.js v22.18.0
error: postinstall script from "simple-git-hooks" exited with 1
If I run the generator with the env var SKIP_INSTALL_SIMPLE_GIT_HOOKS=1, the dependency install step succeeds:
SKIP_INSTALL_SIMPLE_GIT_HOOKS=1 bunx create-inkathon-app@latest
Output:
✔ Repository cloned successfully
✔ Repository cleaned up successfully
✔ Project files updated successfully
✔ Dependencies installed successfully
✖ Failed to generate PAPI types
⚠ Command failed: bun run codegen
$ bun run -F contracts codegen
error: script "codegen" exited with code 1
Trying it manually in the generated repo still getting the issue:
➜ my-inkathon-app git:(master) ✗ bun run -F contracts codegen
contracts codegen $ bash codegen.sh
│
│ Generating types for './deployments/flipper'…
│ error: could not determine executable to run for package papi
└─ Exited with code 1
So it looks like the codegen script expects the papi CLI (Polkadot-API) to be available, but it isn’t yet.
If I then run:
bun add polkadot-api
bun run -F contracts codegen
Everything seems to be generated:
➜ my-inkathon-app git:(master) ✗ bun run -F contracts codegen
contracts codegen $ bash codegen.sh
│ [22 lines elided]
│ Compilation started
│ Compilation successful
│ bun install
│ bun install v1.3.1 (89fa0f34)
│ Saved lockfile
│
│ + @polkadot-api/descriptors@contracts/.papi/descriptors
│ + @polkadot-api/[email protected]
│
│ 6 packages installed [56.00ms]
└─ Done in 8.29 s
But then following the docs if I run:
bun run dev
I get another error with a dependency:
Module not found: Can't resolve '@reactive-dot/core'
./frontend/src/lib/reactive-dot/config.ts (2:1)
Module not found: Can't resolve '@reactive-dot/core'
1 | import { passethub } from "@polkadot-api/descriptors"
> 2 | import { defineConfig } from "@reactive-dot/core"
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
3 | import { InjectedWalletProvider } from "@reactive-dot/core/wallets.js"
4 | import { getWsProvider } from "polkadot-api/ws-provider/web"
Am I missing anything?
Metadata
Metadata
Assignees
Labels
No labels