Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃悰 Bug: Invalid path concatenated while installing nocodb-sdk #7151

Closed
1 task done
chodaprog opened this issue Dec 4, 2023 · 2 comments
Closed
1 task done

馃悰 Bug: Invalid path concatenated while installing nocodb-sdk #7151

chodaprog opened this issue Dec 4, 2023 · 2 comments
Assignees
Labels
馃攷 Status: More Info Needed More information is required to figure out the root cause.

Comments

@chodaprog
Copy link

chodaprog commented Dec 4, 2023

Please confirm if bug report does NOT exists already ?

  • I confirm there is no existing issue for this

Steps to reproduce ?

When trying to install nocodb through npm as mentionned in readme.md

git clone https://github.com/nocodb/nocodb-seed .
npm install
npm start

The package nocodb-sdk won't install, thus making the whole install fail.
It seems there is a "/lib" string concatenated to the relative path.

npm ERR! npm ERR! code ENOENT
npm ERR! npm ERR! syscall lstat
npm ERR! npm ERR! path /root_dir/nodevenv/working_dir/20/lib/lib
npm ERR! npm ERR! errno -2
npm ERR! npm ERR! enoent ENOENT: no such file or directory, lstat '/root_dir/nodevenv/working_dir/20/lib/lib'

I have a two-folder structure :

  • One folder where my files for the nocodb instance are located :
/root_dir/working_dir/
   |_ package.json
   |_ index.js
   |_ etc.
   |_ node_modules/ (symlink to /root_dir/venv/working_dir/20/lib/node_modules/)
  • A second folder with the venv (nodejs 20) located :
/root_dir/venv/working_dir/20/
  |_bin/
  |_lib/
     |_node_modules/
     |_package.json (symlink to /root_dir/working_dir/package.json/)

Other packages in package.json than "nocodb" have been installed separatly successfully.

Here is the full error thrown

npm verb stack Error: command failed
npm verb stack     at ChildProcess.<anonymous> (/opt/alt/alt-nodejs20/root/usr/lib/node_modules/npm/node_modules.bundled/@npmcli/promise-spawn/lib/index.js:53:27)
npm verb stack     at ChildProcess.emit (node:events:514:28)
npm verb stack     at maybeClose (node:internal/child_process:1105:16)
npm verb stack     at ChildProcess._handle.onexit (node:internal/child_process:305:5)
npm verb pkgid nocodb-sdk@0.202.9
npm verb cwd /root_dir/working_dir
npm verb Linux 3.10.0-962.3.2.lve1.5.79.el7.x86_64
npm verb node v20.9.0
npm verb npm  v10.1.0
npm ERR! code 254
npm ERR! path /root_dir/nodevenv/working_dir/20/lib/node_modules/nocodb-sdk
npm ERR! command failed
npm ERR! command sh -c npx only-allow pnpm
npm ERR! npm verb cli /opt/alt/alt-nodejs20/root/usr/bin/node /opt/alt/alt-nodejs20/root/usr/lib/node_modules/npm/bin/npm-cli.js
npm ERR! npm info using npm@10.1.0
npm ERR! npm info using node@v20.9.0
npm ERR! npm verb title npm exec only-allow pnpm
npm ERR! npm verb argv "exec" "--" "only-allow" "pnpm"
npm ERR! npm verb logfile logs-max:10 dir:/root_dir/.npm/_logs/2023-12-04T17_26_20_172Z-
npm ERR! npm verb logfile /root_dir/.npm/_logs/2023-12-04T17_26_20_172Z-debug-0.log
npm ERR! npm http fetch GET 200 https://registry.npmjs.org/only-allow 464ms (cache revalidated)
npm ERR! npm verb stack Error: ENOENT: no such file or directory, lstat '/root_dir/nodevenv/working_dir/20/lib/lib'
npm ERR! npm verb cwd /root_dir/nodevenv/working_dir/20/lib/node_modules/nocodb-sdk
npm ERR! npm verb Linux 3.10.0-962.3.2.lve1.5.79.el7.x86_64
npm ERR! npm verb node v20.9.0
npm ERR! npm verb npm  v10.1.0
npm ERR! npm ERR! code ENOENT
npm ERR! npm ERR! syscall lstat
npm ERR! npm ERR! path /root_dir/nodevenv/working_dir/20/lib/lib
npm ERR! npm ERR! errno -2
npm ERR! npm ERR! enoent ENOENT: no such file or directory, lstat '/root_dir/nodevenv/working_dir/20/lib/lib'
npm ERR! npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! npm ERR! enoent
npm ERR! npm verb exit -2
npm ERR! npm verb code -2
npm ERR!
npm ERR! npm ERR! A complete log of this run can be found in: /root_dir/.npm/_logs/2023-12-04T17_26_20_172Z-debug-0.log
npm verb exit 254
npm verb unfinished npm timer reify 1701710778379
npm verb unfinished npm timer reify:build 1701710779647
npm verb unfinished npm timer build 1701710779648
npm verb unfinished npm timer build:deps 1701710779648
npm verb unfinished npm timer build:run:preinstall 1701710779650
npm verb unfinished npm timer build:run:preinstall:node_modules/nocodb-sdk 1701710779651
npm verb code 254

Desired Behavior

I'd like to go through the whole npm install process without failure.

Project Details

Nocodb used as docker : false
Nocodb version : 0.202.9
OS version : Linux 3.10.0-962.3.2.lve1.5.79.el7.x86_64
Node version : v20.9.0
Npm version : v10.1.0

Attachments

No response

@wingkwong
Copy link
Member

wingkwong commented Dec 5, 2023

@chodaprog I couldn't reproduce. Please DM me at Discord (ID: wingkwong).

image
Node: **v20.10.0**
Arch: **arm64**
Platform: **darwin**
Docker: **false**
RootDB: **sqlite3**
PackageVersion: **0.202.9**

@dstala dstala added the 馃攷 Status: More Info Needed More information is required to figure out the root cause. label Dec 5, 2023
@chodaprog
Copy link
Author

chodaprog commented Dec 5, 2023

I could not recreate this error on my dev env.
Mitigation was to create a symlink for the non-existing folder pointing to its parent. No loop issues.

My pre-prod & prod env uses Cloudlinux nodejs selector. Might come from invalid config, although I could see no incorrect parameters in paths variable declarations.

Sorry for the inconvenience

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
馃攷 Status: More Info Needed More information is required to figure out the root cause.
Projects
None yet
Development

No branches or pull requests

4 participants