Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🛠 Tooling: Running lint before and after building project, yields different errors #1478

Closed
3 tasks done
rubiesonthesky opened this issue Mar 29, 2024 · 2 comments · Fixed by #1479
Closed
3 tasks done
Assignees
Labels
area: tooling Managing the repository's maintenance 🛠️ status: accepting prs Please, send a pull request to resolve this! 🙏

Comments

@rubiesonthesky
Copy link
Collaborator

Bug Report Checklist

  • I have tried restarting my IDE and the issue persists.
  • I have pulled the latest main branch of the repository.
  • I have searched for related issues and found none that matched my issue.

Overview

When I run pnpm lint on project, it reports no errors. But when I run pnpm build first and then pnpm lint, I will get result "1873 problems (1870 errors, 3 warnings)". So using build affects the linting.

However, I was able to find a fix for this. Adding "exclude": ["lib"] to tsconfig.eslint.json file will remove those extra lint errors that seem to be incorrect.

  • Add exclude to tsconfig.eslint.json
  • Update DEVELOPMENT.md to remove mention that you need to run build before linting.

Additional Info

No response

@rubiesonthesky rubiesonthesky added the area: tooling Managing the repository's maintenance 🛠️ label Mar 29, 2024
@rubiesonthesky rubiesonthesky self-assigned this Mar 29, 2024
@rubiesonthesky rubiesonthesky added the status: accepting prs Please, send a pull request to resolve this! 🙏 label Mar 29, 2024
@JoshuaKGoldberg
Copy link
Owner

@all-contributors please add @rubiesonthesky for maintenance.

🤖 Beep boop! This comment was added automatically by all-contributors-auto-action.
Not all contributions can be detected from Git & GitHub alone. Please comment any missing contribution types this bot missed.
...and of course, thank you for contributing! 💙

Copy link
Contributor

@JoshuaKGoldberg

I've put up a pull request to add @rubiesonthesky! 🎉

I couldn't determine any contributions to add, did you specify any contributions?
Please make sure to use valid contribution names.

rubiesonthesky pushed a commit that referenced this issue Mar 30, 2024
Adds @rubiesonthesky as a contributor for maintenance.

This was requested by JoshuaKGoldberg [in this
comment](#1478 (comment))

---------

Co-authored-by: allcontributors[bot] <46447321+allcontributors[bot]@users.noreply.github.com>
JoshuaKGoldberg pushed a commit that referenced this issue Mar 30, 2024
<!-- 👋 Hi, thanks for sending a PR to TypeStat! 💖.
Please fill out all fields below and make sure each item is true and [x]
checked.
Otherwise we may not be able to review your PR. -->

## PR Checklist

- [x] Addresses an existing open issue: fixes #1487 
- [x] That issue was marked as [`status: accepting
prs`](https://github.com/JoshuaKGoldberg/TypeStat/issues?q=is%3Aopen+is%3Aissue+label%3A%22status%3A+accepting+prs%22)
- [x] Steps in
[CONTRIBUTING.md](https://github.com/JoshuaKGoldberg/TypeStat/blob/main/.github/CONTRIBUTING.md)
were taken 🐶

## Overview

<!-- Description of what is changed and how the code change does that.
-->

~~I'm trying to see, will this fix inconsistency between local and CI
lint run~~

This just updates the action version. The inconsistency was because of
unrelated reason, see #1478

Co-authored-by: rubiesonthesky <rubiesonthesky>
JoshuaKGoldberg pushed a commit that referenced this issue Mar 30, 2024
…eporting

<!-- 👋 Hi, thanks for sending a PR to TypeStat! 💖.
Please fill out all fields below and make sure each item is true and [x]
checked.
Otherwise we may not be able to review your PR. -->

## PR Checklist

- [x] Addresses an existing open issue: fixes #1478
- [x] That issue was marked as [`status: accepting
prs`](https://github.com/JoshuaKGoldberg/TypeStat/issues?q=is%3Aopen+is%3Aissue+label%3A%22status%3A+accepting+prs%22)
- [x] Steps in
[CONTRIBUTING.md](https://github.com/JoshuaKGoldberg/TypeStat/blob/main/.github/CONTRIBUTING.md)
were taken

## Overview

<!-- Description of what is changed and how the code change does that.
-->

Eslint has different result depending on if `lib`folder is present or
not. When it is present, lint errors seems incorrect.

Excluding "lib" from eslint fixes the issue. Also, removed mention that
you should build the project before linting. This is not done in CI and
it seems unnecessary in current state. :)

Co-authored-by: rubiesonthesky <rubiesonthesky>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: tooling Managing the repository's maintenance 🛠️ status: accepting prs Please, send a pull request to resolve this! 🙏
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants