ibi-group / datatools-ui

Core application for IBI's transit data tools suite.
https://data-tools-docs.ibi-transit.com/en/latest/
MIT License
121 stars 80 forks source link

Error running yarn #770

Open dancesWithCycles opened 2 years ago

dancesWithCycles commented 2 years ago

Observed behavior (please include a screenshot if possible)

The latest (v4.1.0) version says in the documentation to run yarn to install dependencies.

Mastarm says in the documentation that it needs node version 8 and npm version 5.

As a consequence yarn complains about the following issue.

begerad@ltpt490:~/git/ibi-group/datatools-ui$ nvm use v8.0.0
Now using node v8.0.0 (npm v5.0.0)
begerad@ltpt490:~/git/ibi-group/datatools-ui$ node -v
v8.0.0
begerad@ltpt490:~/git/ibi-group/datatools-ui$ npm -v
5.0.0
begerad@ltpt490:~/git/ibi-group/datatools-ui$ npm i -g yarn

> yarn@1.22.17 preinstall /home/begerad/.nvm/versions/node/v8.0.0/lib/node_modules/yarn
> :; (node ./preinstall.js > /dev/null 2>&1 || true)

/home/begerad/.nvm/versions/node/v8.0.0/bin/yarn -> /home/begerad/.nvm/versions/node/v8.0.0/lib/node_modules/yarn/bin/yarn.js
/home/begerad/.nvm/versions/node/v8.0.0/bin/yarnpkg -> /home/begerad/.nvm/versions/node/v8.0.0/lib/node_modules/yarn/bin/yarn.js
updated 1 package in 0.957s
begerad@ltpt490:~/git/ibi-group/datatools-ui$ yarn -v
1.22.17
begerad@ltpt490:~/git/ibi-group/datatools-ui$ yarn
yarn install v1.22.17
[1/4] Resolving packages...
[2/4] Fetching packages...
error execa@2.0.4: The engine "node" is incompatible with this module. Expected version "^8.12.0 || >=9.7.0". Got "8.0.0"
error Found incompatible module.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
begerad@ltpt490:~/git/ibi-group/datatools-ui$ 

Expected behaviour

I expected yarn to install dependencies.

Steps to reproduce the problem

You see the steps above to reproduce this behaviour.

Any special notes on configuration used

I did not touch the config files in this repository and neither supplied a path to other config files.

dancesWithCycles commented 2 years ago

Yarn keeps complaining when I increase the node version.

begerad@ltpt490:~/git/ibi-group/datatools-ui$ nvm install 8.12.0^C
begerad@ltpt490:~/git/ibi-group/datatools-ui$ nvm use v8.12.0
Now using node v8.12.0 (npm v6.4.1)
begerad@ltpt490:~/git/ibi-group/datatools-ui$ node -v
v8.12.0
begerad@ltpt490:~/git/ibi-group/datatools-ui$ npm -v
6.4.1
begerad@ltpt490:~/git/ibi-group/datatools-ui$ npm i -g yarn

> yarn@1.22.17 preinstall /home/begerad/.nvm/versions/node/v8.12.0/lib/node_modules/yarn
> :; (node ./preinstall.js > /dev/null 2>&1 || true)

/home/begerad/.nvm/versions/node/v8.12.0/bin/yarn -> /home/begerad/.nvm/versions/node/v8.12.0/lib/node_modules/yarn/bin/yarn.js
/home/begerad/.nvm/versions/node/v8.12.0/bin/yarnpkg -> /home/begerad/.nvm/versions/node/v8.12.0/lib/node_modules/yarn/bin/yarn.js
+ yarn@1.22.17
added 1 package in 0.787s
begerad@ltpt490:~/git/ibi-group/datatools-ui$ yarn -v
1.22.17
begerad@ltpt490:~/git/ibi-group/datatools-ui$ yarn
yarn install v1.22.17
[1/4] Resolving packages...
[2/4] Fetching packages...
error mastarm@5.3.1: The engine "node" is incompatible with this module. Expected version ">=10". Got "8.12.0"
error Found incompatible module.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
dancesWithCycles commented 2 years ago

Node version v10.0.0 worked for yarn to install dependencies as you can see the response below.

begerad@ltpt490:~/git/ibi-group/datatools-ui$ nvm install 10.0.0
v10.0.0 is already installed.
Now using node v10.0.0 (npm v5.6.0)
begerad@ltpt490:~/git/ibi-group/datatools-ui$ nvm use v10.0.0
Now using node v10.0.0 (npm v5.6.0)
begerad@ltpt490:~/git/ibi-group/datatools-ui$ node -v
v10.0.0
begerad@ltpt490:~/git/ibi-group/datatools-ui$ npm -v
5.6.0
begerad@ltpt490:~/git/ibi-group/datatools-ui$ npm i -g yarn

> yarn@1.22.17 preinstall /home/begerad/.nvm/versions/node/v10.0.0/lib/node_modules/yarn
> :; (node ./preinstall.js > /dev/null 2>&1 || true)

/home/begerad/.nvm/versions/node/v10.0.0/bin/yarnpkg -> /home/begerad/.nvm/versions/node/v10.0.0/lib/node_modules/yarn/bin/yarn.js
/home/begerad/.nvm/versions/node/v10.0.0/bin/yarn -> /home/begerad/.nvm/versions/node/v10.0.0/lib/node_modules/yarn/bin/yarn.js
+ yarn@1.22.17
added 1 package in 0.851s
begerad@ltpt490:~/git/ibi-group/datatools-ui$ yarn -v
1.22.17
begerad@ltpt490:~/git/ibi-group/datatools-ui$ yarn
yarn install v1.22.17
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
warning " > enzyme-adapter-react-15.4@1.3.1" has incorrect peer dependency "react@15.0.0-0 - 15.4.x".
warning " > enzyme-adapter-react-15.4@1.3.1" has incorrect peer dependency "react-dom@15.0.0-0 - 15.4.x".
warning " > enzyme-adapter-react-15.4@1.3.1" has incorrect peer dependency "react-addons-test-utils@15.0.0-0 - 15.4.x".
warning "mastarm > eslint-plugin-flowtype@3.12.2" has incorrect peer dependency "eslint@>=6.0.0".
[4/4] Building fresh packages...
Done in 328.40s.
begerad@ltpt490:~/git/ibi-group/datatools-ui$ 

Is this the way supposed to set up node for this repository in the v4.1.0 release/tag?

miles-grant-ibigroup commented 2 years ago

Yes, datatools requires node 10, although we recommend node 14.

dancesWithCycles commented 2 years ago

Hi @miles-grant-ibigroup , Thank you very much for the prompt response and the clarification. Do you think it is of value to add a line like ...datatools requires node 10, although we recommend node 14... to the documentation?

miles-grant-ibigroup commented 2 years ago

Yes updating the documentation (along with a few other changes) is in our backlog. We are a bit behind on tasks like this, so again feel free to make a PR that updates the docs with this change and any other issues you may notice! I generally am able to review