I am trouble building my code

Hi when I am trying to build my code I am getting an ./build-curriculum’ not found . here is the full stack trace below

Error: Cannot find module ‘./build-curriculum’
Require stack:

  • /Users/anishlukkireddy/freeCodeCamp/tools/scripts/build/imaginaryUncacheableRequireResolveScript
    at Function.resolveFilename (node:internal/modules/cjs/loader:1394:15)
    at Function.resolve (node:internal/modules/helpers:145:19)
    at requireResolveNonCached (/Users/anishlukkireddy/freeCodeCamp/node_modules/.pnpm/ts-node@10.9.2
    @types+node@20.12.8_typescript@5.7.3/node_modules/ts-node/dist/bin.js:549:16)
    at getProjectSearchDir (/Users/anishlukkireddy/freeCodeCamp/node_modules/.pnpm/ts-node@10.9.2_@types+node@20.12.8_typescript@5.7.3/node_modules/ts-node/dist/bin.js:519:40)
    at phase3 (/Users/anishlukkireddy/freeCodeCamp/node_modules/.pnpm/ts-node@10.9.2_@types+node@20.12.8_typescript@5.7.3/node_modules/ts-node/dist/bin.js:267:27)
    at bootstrap (/Users/anishlukkireddy/freeCodeCamp/node_modules/.pnpm/ts-node@10.9.2_@types+node@20.12.8_typescript@5.7.3/node_modules/ts-node/dist/bin.js:47:30)
    at main (/Users/anishlukkireddy/freeCodeCamp/node_modules/.pnpm/ts-node@10.9.2_@types+node@20.12.8_typescript@5.7.3/node_modules/ts-node/dist/bin.js:33:12)
    at Object. (/Users/anishlukkireddy/freeCodeCamp/node_modules/.pnpm/ts-node@10.9.2_@types+node@20.12.8_typescript@5.7.3/node_modules/ts-node/dist/bin.js:579:5)
    at Module._compile (node:internal/modules/cjs/loader:1723:14)
    at Object…js (node:internal/modules/cjs/loader:1888:10) {
    code: ‘MODULE_NOT_FOUND’,
    requireStack: [
    ‘/Users/anishlukkireddy/freeCodeCamp/tools/scripts/build/imaginaryUncacheableRequireResolveScript’
    ]
    }

I tried the cleaning the workspace and running the commands in the trouble shooting section, deleting the repo and cloning it again, and finally the commands to run for build erros in the trouble shooting section. I think the error might be due to my node and npm version. is that true

The missing ./build-curriculum module is odd. Likely a version mismatch with Node/npm. Check your versions against the contribution guide, and run npm install to ensure all deps are up-to-date.

1 Like

what command are you using that gives this error?

npm error Cannot read properties of null (reading ‘name’)
npm error A complete log of this run can be found in: /Users/anishlukkireddy/.npm/_logs/2025-02-18T22_59_22_357Z-debug-0.log this is what i got when i ran npm install

pnpm run develop is the command I try to run

I noticed that the file is there and none of the scripts is working

I would check what node version you have, and also run pnpm install again, and also copy again the .env file

I checked my node version and I have 23.7

I also tried pnpm install and copying the .env file and it failed

What system are you using? are you developing on windows? that is not supported, you would need to use a Linux environment, or WSL

I am using a mac , so I am not sure that applies

that is an environment that is supported, yes

try starting from the beginning again and keep all the logs you get, there may be something earlier

this used to work , but I will try again

varius things have been changed lately

maybe you need a stable version of node? try node v22
and make sure to copy the .env file again if you haven’t done so recently

I try this again but I still get the same error

I have no idea why that error appears, are you sure you followed all instructions?

Try running

rm pnpm-lock.yaml
pnpm i

Hope this helps

It didn’t work for me

I have the same issue, and my version of Node is 23.7.0. I also have followed all the instructions for the setup.

have you trying to use Node 22? 23 is not a stable version