blueprint icon indicating copy to clipboard operation
blueprint copied to clipboard

Blueprint doesn't work with "moduleResolution": "bundler"

Open XantreDev opened this issue 10 months ago • 3 comments

blueprint build doesn't work with moduleResolution

{
  "extends": "@tsconfig/node20/tsconfig.json",
  "compilerOptions": {
    "resolveJsonModule": true,
    "module": "Preserve",
    "moduleResolution": "bundler"
  }
}
D:\Projects\my-learn\ton-contract> npx blueprint build                                                                                                                       1 01/21/2025 09:24:28 PM
Error: ENOENT: no such file or directory, scandir 'D:\Projects\my-learn\ton-contract\wrappers'
    at async Object.readdir (node:internal/fs/promises:948:18)
    at async findCompiles (D:\Projects\my-learn\ton-contract\node_modules\.pnpm\@[email protected]_@[email protected]_@[email protected]_@[email protected]_rt4e6qdu5c7mzkkkcx7zvte7j4\node_modules\@ton\blueprint\dist\utils\selection.utils.js:37:19)
    at async selectCompile (D:\Projects\my-learn\ton-contract\node_modules\.pnpm\@[email protected]_@[email protected]_@[email protected]_@[email protected]_rt4e6qdu5c7mzkkkcx7zvte7j4\node_modules\@ton\blueprint\dist\cli\build.js:12:42)
    at async build (D:\Projects\my-learn\ton-contract\node_modules\.pnpm\@[email protected]_@[email protected]_@[email protected]_@[email protected]_rt4e6qdu5c7mzkkkcx7zvte7j4\node_modules\@ton\blueprint\dist\cli\build.js:32:21)
    at async main (D:\Projects\my-learn\ton-contract\node_modules\.pnpm\@[email protected]_@[email protected]_@[email protected]_@[email protected]_rt4e6qdu5c7mzkkkcx7zvte7j4\node_modules\@ton\blueprint\dist\cli\cli.js:91:5) {
  errno: -4058,
  code: 'ENOENT',
  syscall: 'scandir',
  path: 'D:\\Projects\\my-learn\\ton-contract\\wrappers'
}

If module is classic in tsconfig.json it works:

{
  "extends": "@tsconfig/node20/tsconfig.json",
  "compilerOptions": {
    "resolveJsonModule": true,
    "module": "NodeNext",
    "moduleResolution": "nodenext"
  }
}
D:\Projects\my-learn\ton-contract> npx blueprint build                                                                                                                       1 01/21/2025 09:24:48 PM
Using file: MainContract
Build script running, compiling MainContract

✅ Compiled successfully! Cell BOC result:

{
  "hash": "4834417f4be3ad0ec96e1d6d60c2ba9c86113ee51cfc9c68cb974853f1e0a6a7",

XantreDev avatar Jan 21 '25 20:01 XantreDev

Probably it's an issue with ts-node

XantreDev avatar Jan 21 '25 20:01 XantreDev

Not reprodusable locally, could you please prepare repo with reproduce steps? It would help a lot, thanks

Alejandbel avatar Apr 28 '25 15:04 Alejandbel

I will try to reproduce it again in next couple of days

XantreDev avatar Apr 28 '25 21:04 XantreDev