Skip to content

Fail "new primer" runs on fatal errors, like "old primer" #6746

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

Merged
merged 8 commits into from
May 30, 2022

Conversation

jacobtylerwalls
Copy link
Member

Type of Changes

Type
βœ“ πŸ”¨ Refactoring

Description

The old primer did one thing very well -- it failed CI jobs when encountering fatal errors during the linting of open source packages, whether caused in new pylint or astroid PRs, or when adding new packages to the primer, or when third-party packages pushed new changes.

The new primer needs some analogous functionality -- something beyond the message differ. If some fatal errors "sneak in" (we merge a PR without noticing the change, or we believe it to be related to a different PR, or incompatible PRs are merged, or we add a package, or third-party maintainers publish new commits), we don't want n fatal errors on main to silently match n fatal errors on a PR and for the comment-bot to stay quiet about it. We want a failure.

I persuaded (πŸ’ͺ🏻 πŸ˜… πŸ™πŸ» πŸ“ˆ ) us into running the primer on bleeding-edge astroid, and from the feedback that we want to be careful not to introduce a dependency in pylint's CI on bleeding-edge astroid with respect to failing jobs (because that is more significant than simply the contents of a bot's comments on a PR), I filter those out here and just issue a warning instead.

@github-actions

This comment has been minimized.

@coveralls
Copy link

coveralls commented May 30, 2022

Pull Request Test Coverage Report for Build 2411224946

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 95.516%

Totals Coverage Status
Change from base Build 2410487754: 0.0%
Covered Lines: 16230
Relevant Lines: 16992

πŸ’› - Coveralls

@github-actions

This comment has been minimized.

Copy link
Member

@Pierre-Sassoulas Pierre-Sassoulas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's the best of both world πŸ‘Œ

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@jacobtylerwalls
Copy link
Member Author

This will need a preparatory commit on main to make sure all astroid failures are re-raised as a flavor of AstroidError.

@github-actions

This comment has been minimized.

@github-actions
Copy link
Contributor

πŸ€– According to the primer, this change has no effect on the checked open source code. πŸ€–πŸŽ‰

@jacobtylerwalls
Copy link
Member Author

Here's a proof of concept showing a passing CI job on the primer and an Actions warning annotation with the traceback from astroid: Run / 3.8

@jacobtylerwalls jacobtylerwalls merged commit c29bba6 into pylint-dev:main May 30, 2022
@jacobtylerwalls jacobtylerwalls deleted the fail-loudly branch June 12, 2022 13:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants