Lint broken with latest version on our CI
See original GitHub issueExpected Behavior
Lint running well
Current Behavior
Lint breaks
Failure Information (for bugs)
After upgrading to v8.7.0 from v8.6.0 lint breaks with the following error message on our CI:
Error: Command failed: git merge-base master HEAD
fatal: Not a valid object name master
command:
$ npm run lint
> nx workspace-lint && nx affected:lint --parallel --all --maxParallel 4
Runs well locally. Runs well on CI with v8.6.0.
Steps to Reproduce
nx affected:lint --parallel --all --maxParallel 4
Context
- nx v8.7.0
- gitlab CI
- works well with nx v8.6.0
Failure Logs
Error: Command failed: git merge-base master HEAD
fatal: Not a valid object name master
at checkExecSyncError (child_process.js:629:11)
at Object.execSync (child_process.js:666:13)
at getFilesUsingBaseAndHead (/builds/[repo]/node_modules/@nrwl/workspace/src/command-line/shared.js:108:39)
at Object.parseFiles (/builds/[repo]/node_modules/@nrwl/workspace/src/command-line/shared.js:93:20)
at Object.affected (/builds/[repo]/node_modules/@nrwl/workspace/src/command-line/affected.js:16:35)
at Object.exports.commandsObject.yargs.usage.command.command.command.command.command.command.command.command.command.command.command.args [as handler] (/builds/[repo]/node_modules/@nrwl/workspace/src/command-line/nx-commands.js:66:138)
at Object.runCommand (/builds/[repo]/node_modules/@nrwl/workspace/node_modules/yargs/lib/command.js:235:44)
at Object.parseArgs [as _parseArgs] (/builds/[repo]/node_modules/@nrwl/workspace/node_modules/yargs/yargs.js:1022:30)
at Object.get [as argv] (/builds/[repo]/node_modules/@nrwl/workspace/node_modules/yargs/yargs.js:965:21)
at Object.<anonymous> (/builds/[repo]/node_modules/@nrwl/cli/bin/nx.js:38:26)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [repo]@1.0.0 lint: `nx workspace-lint && nx affected:lint --parallel --all --maxParallel 4`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [repo]@1.0.0 lint script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
Issue Analytics
- State:
- Created 4 years ago
- Comments:8 (3 by maintainers)
Top Results From Across the Web
Unexplained CI Lint Failures (#207320) · Issues - GitLab
A customer has several projects with CI/CID pipelines that use the "needs" keyword. Inexplicably yaml invalid and error messages appear for ...
Read more >Install | golangci-lint
Versioning Policy · A patch version update in a specific linter that results in golangci-lint reporting fewer errors. · A bug fix to...
Read more >Performance Tuning - Google Samples
Try using the latest versions of lint (the Android Gradle plugin), as well as of Gradle — even if that means using a...
Read more >How to Use GitHub Super Linter in Your Projects
We will name this job "Lint Code Base" and ask GitHub to run our job on a runner with the last version of...
Read more >README - semantic-release
semantic-release is meant to be executed on the CI environment after every ... Obtain the commit corresponding to the last release by analyzing...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

When using Merge Requests on GitLab CI
git merge-base master HEADwon’t work on the runners. You’ll need to rungit fetch originbefore anything else.I can confirm that
git fetch originhelps on Gitlab CI..gitlab-ci.yml:package.json: