Help for Lift-off part 1 Odyssey course

Hey there! Thank you for starting your journey with us on Odyssey.
This is the topic to find help on the very first Odyssey course Lift-off part 1.

3 Likes
  1. APOLLO CLIENT SETUP

After including ApolloProvider getting the below error.
./node_modules/@apollo/client/core/index.js
"export ‘setVerbosity’ (reexported as ‘setLogVerbosity’) was not found in ‘ts-invariant’

Kindly advice on this.

Cheers,
Anguram Shanmugam

Hi Anguram!

I’d like to clarify the steps you took to get to this error. Did you install the packages with npm install graphql @apollo/client inside the client folder?

Could you also paste the code you have from your index.js file? I’d like to see how you’re using the ApolloProvider component.

Thanks!

Glad to hear from you. Unfortunately I’m AFK. The issue is with the presence of “StrictMode” from React. After removal and restart it’s working.

But why this behaviour? I don’t know :thinking:

Anyways!

cheers,
Anguram Shanmugam

I wasn’t able to reproduce the error on my end, following the lesson instructions and keeping React.StrictMode on, so I’m not sure why you were getting that error! Feel free to post your code when you’re able and we can take a closer look :slight_smile:

I just read an article about npm audit fix --force. I just ran that now everthing’s fine. Use the below project link If you wanna see the code.

Odyssey: Lift-Off-part-1

cheers,
Anguram Shanmugam

Hi Support Community - I’m running VSCode on Ubuntu 20.04 LTS. I am unable to get beyond npm start | yarn start:

Logs below:
7 . The front-end app
From the client/ directory, run: npm start | yarn start

npm start

catstronauts-client-complete@1.0.0 start
react-scripts start

sh: 1: react-scripts: not found

yarn run v1.22.5
$ react-scripts start
/bin/sh: 1: react-scripts: not found
error Command failed with exit code 127.



$ npm install react-scripts

[sudo] password for m:
npm notice
npm notice New minor version of npm available! 7.16.0 → 7.17.0
npm notice Changelog: Release v7.17.0 · npm/cli · GitHub
npm notice Run npm install -g npm@7.17.0 to update!
npm notice
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: catstronauts-client-complete@1.0.0
npm ERR! Found: react@16.14.0
npm ERR! node_modules/react
npm ERR! react@"^16.13.1" from the root project
npm ERR! peer react@">=16.8 || ^17.0.0" from framer-motion@4.1.17
npm ERR! node_modules/framer-motion
npm ERR! peer framer-motion@">1.6" from @apollo/space-kit@7.21.0
npm ERR! node_modules/@apollo/space-kit
npm ERR! @apollo/space-kit@"^7.11.0" from the root project
npm ERR! 1 more (react-dom)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@">16" from @apollo/space-kit@7.21.0
npm ERR! node_modules/@apollo/space-kit
npm ERR! @apollo/space-kit@"^7.11.0" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See /root/.npm/eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2021-06-16T08_07_45_131Z-debug.log

Hi @weiss!

To confirm, have you ran npm install in the client directory before running npm start?

Hi,

Yes, and I tried again.

/client$ npm install

npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: catstronauts-client-complete@1.0.0
npm ERR! Found: react@16.14.0
npm ERR! node_modules/react
npm ERR! react@"^16.13.1" from the root project
npm ERR! peer react@">=16.8 || ^17.0.0" from framer-motion@4.1.17
npm ERR! node_modules/framer-motion
npm ERR! peer framer-motion@">1.6" from @apollo/space-kit@7.21.0
npm ERR! node_modules/@apollo/space-kit
npm ERR! @apollo/space-kit@"^7.11.0" from the root project
npm ERR! 1 more (react-dom)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@">16" from @apollo/space-kit@7.21.0
npm ERR! node_modules/@apollo/space-kit
npm ERR! @apollo/space-kit@"^7.11.0" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See /home/m/.npm/eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR! /home/m/.npm/_logs/2021-06-16T19_56_27_863Z-debug.log


I made sure to remove any package lock.json file and tried but no success. All attempted in the /client directory.