question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

auto_fix: true fails when there are no changes to commit

See original GitHub issue
  Verifying setup for ESLint…
  Verified ESLint setup
  Will use ESLint to check the files with extensions js
  Linting and auto-fixing files in /home/runner/work/***/*** with ESLint…
  ESLint found 6 errors (failure)
  Changes found with Git
  Committing changes
  Error: Error: Command failed: git commit -am "Fix code style issues with ESLint"
  /home/runner/work/_actions/wearerequired/lint-action/v1/dist/index.js:1108
  	throw new Error(`Exiting because of unhandled promise rejection`);
  	^
  
  Error: Exiting because of unhandled promise rejection
      at process.<anonymous> (/home/runner/work/_actions/wearerequired/lint-action/v1/dist/index.js:1108:8)
      at process.emit (events.js:210:5)
      at processPromiseRejections (internal/process/promises.js:201:33)
      at processTicksAndRejections (internal/process/task_queues.js:94:32)```

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:3
  • Comments:8 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
ghostcommented, Jan 22, 2021

@brennanwilkes FWIW, I had success seeing that my runner actually had a modified file outside the linter directory which caused this error for me.

Enabling debug as described here: https://docs.github.com/en/actions/managing-workflow-runs/enabling-debug-logging showed me the file and I was able to git rm and gitignore the file since it was only an “unneeded” file

1reaction
AnthonyLzqcommented, Feb 24, 2022

Wait, I don’t think so, since you haven’t commit yet. Git checkout or restore will return to the previous state of your package-lock.json file.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Extension not auto-fixing on Save #833
I got the upgrade to 2.0.4 (and subsequently to 2.0.5 a little bit ago) and I'm having trouble configuring ESLint to auto-fix issues...
Read more >
error: Could not read from object database for commit-graph
We have a client that noticed errors in the Repocheck.log for a specific repository, but was unable to replicate the errors locally or ......
Read more >
How to git commit nothing without an error?
The current answer, git diff-index --quiet HEAD (no --cached ), will not produce the correct result if there are differences only between the ......
Read more >
Auto-squashing Git Commits
For my typo fix, there's no need to modify the original commit message so I can use --fixup and pass the commit that...
Read more >
Automatically format and lint code with pre-commit - Interrupt
No, by default if pre-commit makes changes it will reject the commit so you can review the changes. The well-trained monkey at the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found