Describe the bug
It looks like Codacy isn't able to leverage the @types/git-url-parse package, which results in odd error messages. Specifically, it gives the following:
Unsafe assignment of an error typed value.
Unsafe call of an `error` type typed value.
I don't believe there is an error type that could possibly apply here, suggesting that it's badly communicated error.
Describe the bug It looks like Codacy isn't able to leverage the @types/git-url-parse package, which results in odd error messages. Specifically, it gives the following:
Unsafe assignment of an error typed value.
Unsafe call of an `error` type typed value.
I don't believe there is an
error
type that could possibly apply here, suggesting that it's badly communicated error.This was observed with https://github.com/flxbl-io/sfp/pull/138, where the above error messages were generated.
To Reproduce
@type
library not appearing in this file: https://github.com/codacy/codacy-eslint/blob/master/package.json. (E.g., thegit-url-parse
package insrc/core/package/SfpPackageInquirer.ts
);Expected behavior The code passes without error (in the case of the referenced PR) or the error messages would make more sense.
Screenshots
Platform Details (please complete the following information): This is with GitHub workflow on the https://github.com/flxbl-io/sfp/pull/138 PR.
Additional context It looks like this may be a limitation of how Codacy is configured/works. I found an old GitHub Issue (from back before when they hid their Issues) that says that they don't do an
npm install
when running on their cloud, and that is causing the error. https://web.archive.org/web/20201123173420/https://github.com/codacy/codacy-eslint/issues/920This report is from 2020, so it may no longer be relevant. However, it would explain the
error
type.If this turns out to be the case, the solution is likely move the checks into the GitHub workflow:
npm install
npm run build