Dependency fail

12:53:26 PM: build-image version: 91488c6c0412f5c1c00fb34eff5c1fc41a32bce9 (focal)
12:53:26 PM: buildbot version: 91488c6c0412f5c1c00fb34eff5c1fc41a32bce9
12:53:26 PM: Building without cache
12:53:26 PM: Starting to prepare the repo for build
12:53:26 PM: No cached dependencies found. Cloning fresh repo
12:53:26 PM: git clone --filter=blob:none GitHub - koolkusum/Kusum_Gandham: Netlify Portfolio
12:53:26 PM: Preparing Git Reference refs/heads/main
12:53:32 PM: Parsing package.json dependencies
12:53:33 PM: Different build command detected, going to use the one specified in the Netlify configuration file: ‘CI= npm run build’ versus ‘CI=’’ npm run build’ in the Netlify UI
12:53:33 PM: Starting to install dependencies
12:53:33 PM: Python version set to 3.8
12:53:33 PM: Attempting Ruby version 2.7.2, read from environment
12:53:34 PM: Using Ruby version 2.7.2
12:53:34 PM: Started restoring cached go cache
12:53:34 PM: Finished restoring cached go cache
12:53:34 PM: Installing Go version 1.19.5 (requested 1.19.5)
12:53:39 PM: go version go1.19.5 linux/amd64
12:53:39 PM: Using PHP version 8.0
12:53:40 PM: v16.20.0 is already installed.
12:53:40 PM: Now using node v16.20.0 (npm v8.19.4)
12:53:41 PM: Enabling Node.js Corepack
12:53:41 PM: Started restoring cached build plugins
12:53:41 PM: Finished restoring cached build plugins
12:53:41 PM: Started restoring cached corepack dependencies
12:53:41 PM: Finished restoring cached corepack dependencies
12:53:41 PM: Started restoring cached yarn cache
12:53:41 PM: Finished restoring cached yarn cache
12:53:41 PM: No yarn workspaces detected
12:53:41 PM: Started restoring cached node modules
12:53:42 PM: Finished restoring cached node modules
12:53:42 PM: Installing npm packages using Yarn version 1.22.19
12:53:42 PM: yarn install v1.22.19
12:53:42 PM: error An unexpected error occurred: “Invalid value type 66:0 in /opt/build/repo/yarn.lock”.
12:53:42 PM: info If you think this is a bug, please open a bug report with the information provided in “/opt/build/repo/yarn-error.log”.
12:53:42 PM: info Visit yarn install | Yarn for documentation about this command.
12:53:42 PM: Error during Yarn install
12:53:42 PM: Failed during stage ‘Install dependencies’: dependency_installation script returned non-zero exit code: 1
12:53:42 PM: Build was terminated: dependency_installation script returned non-zero exit code: 1
12:53:42 PM: Failing build: Failed to install dependencies
12:53:42 PM: Finished processing build request in 16.541s

Hi, I made a portfolio react site and it falls here. I am not sure what is wrong. This is the layout of the GitHub I am uploading from as well.

@koolkusum Yarn is running because you have a yarn.lock file, and there is seemingly something wrong with that file.

When I test locally I see precisely the same error.

Just delete the yarn.lock file, so that the dependencies install with npm and you should be fine.

1 Like

Thank you so much this worked!