Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: continue on node package install failure (#236)
### Problem Currently, most of our check-on-prs/check nightly failures occur while installing node packages, for a variety of reasons. Right now, this causes the check to fail, and we report that "something went wrong". Instead, we may want to disable linters that depend on node-modules (specifically, stylelint and eslint) and lint the remaining files to report our best-effort results. Pros: - We would report some issues, and some issues is better than no issues - We wouldn't be erroring with a message that seems like an internal error (because for all we know right now, it could be) Cons: - A user could introduce a lint issue in the same PR as a breaking change to package.json and we would pass that PR - I am pretty sure that we don't have a great way of surfacing to the user that we're disabling eslint without writing an annoying amount of boilerplate to send the data through the cli through services back to github - We do log this in the action logs, but that's the most visible place ### Solution After talking with Sam about this, we figured the best solution is to disable the linters if we are auto-initing for the user, but not if the user has a trunk.yaml and therefore has deliberately opted to see ts/js issues. ### Testing Added a repo test for [prawn-test-staging-rw/node-packages-failure-test](https://github.com/prawn-test-staging-rw/node-packages-failure-test/tree/main) that has an invalid package.json, and checks to make sure the action disables eslint and stylelint, and continues after the failure.
- Loading branch information