Skip to content

Conversation

cdce8p
Copy link
Member

@cdce8p cdce8p commented May 16, 2025

Fix failing spelling tests: https://github.com/pylint-dev/pylint/actions/runs/15076143743/job/42383895655

Prevent using an old cached version of pylint for tests by reinstalling it from source before every pytest run in CI.
Furthermore adding --no-deps since we only care about pylint itself. For everything else, like an updated dependency, the cache is invalidated anyway.

@cdce8p cdce8p added this to the 3.3.8 milestone May 16, 2025
@cdce8p cdce8p added Maintenance Discussion or action around maintaining pylint or the dev workflow Skip news 🔇 This change does not require a changelog entry labels May 16, 2025
Copy link
Contributor

🤖 Effect of this PR on checked open source code: 🤖

Effect on home-assistant:
The following messages are no longer emitted:

  1. unsupported-assignment-operation:
    'self.hass.data[DOMAIN]' does not support item assignment
    https://github.com/home-assistant/core/blob/dbc15a2ddac16b02bde793a4dbc4290af42d5659/homeassistant/components/system_health/__init__.py#L269
  2. unsubscriptable-object:
    Value 'self.hass.data[DOMAIN]' is unsubscriptable
    https://github.com/home-assistant/core/blob/dbc15a2ddac16b02bde793a4dbc4290af42d5659/homeassistant/components/media_source/models.py#L88
  3. unsupported-assignment-operation:
    'self.hass.data[DATA_LAST_WAKE_UP]' does not support item assignment
    https://github.com/home-assistant/core/blob/dbc15a2ddac16b02bde793a4dbc4290af42d5659/homeassistant/components/assist_pipeline/pipeline.py#L800
  4. unsupported-assignment-operation:
    'self.run.hass.data[DATA_LAST_WAKE_UP]' does not support item assignment
    https://github.com/home-assistant/core/blob/dbc15a2ddac16b02bde793a4dbc4290af42d5659/homeassistant/components/assist_pipeline/pipeline.py#L1556

This comment was generated for commit 0582b86

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'm not sure if I understand correctly but what happens if there's no cache at all ? Don't we need the install without --no-deps in this case ?

@cdce8p
Copy link
Member Author

cdce8p commented May 17, 2025

I'm not sure if I understand correctly but what happens if there's no cache at all ? Don't we need the install without --no-deps in this case ?

This already happens during the cache creation step. E.g. for checks.yaml here

- name: Create Python virtual environment
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
python -m venv venv
. venv/bin/activate
python -m pip install --upgrade pip setuptools wheel
pip install --upgrade --requirement requirements_test.txt --requirement doc/requirements.txt
pip install pre-commit

Only added --no-deps to the pip install calls which test something to force the reinstall of pylint from source.
https://github.com/pylint-dev/pylint/actions/runs/15077014530/job/42386657954?pr=10388#step:5:18

@Pierre-Sassoulas Pierre-Sassoulas enabled auto-merge (rebase) May 17, 2025 04:19
@cdce8p cdce8p disabled auto-merge May 17, 2025 04:35
@cdce8p cdce8p merged commit 544a8f1 into pylint-dev:main May 17, 2025
44 of 45 checks passed
@cdce8p cdce8p deleted the ci-install-pylint branch May 17, 2025 04:36
Copy link
Contributor

The backport to maintenance/3.3.x failed:

The process '/usr/bin/git' failed with exit code 1

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-maintenance/3.3.x maintenance/3.3.x
# Navigate to the new working tree
cd .worktrees/backport-maintenance/3.3.x
# Create a new branch
git switch --create backport-10388-to-maintenance/3.3.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 544a8f189c21bcba7144d3440d93bfeb01622e85
# Push it to GitHub
git push --set-upstream origin backport-10388-to-maintenance/3.3.x
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-maintenance/3.3.x

Then, create a pull request where the base branch is maintenance/3.3.x and the compare/head branch is backport-10388-to-maintenance/3.3.x.

@Pierre-Sassoulas Pierre-Sassoulas removed this from the 3.3.8 milestone May 17, 2025
Pierre-Sassoulas added a commit that referenced this pull request May 17, 2025
@cdce8p cdce8p added this to the 4.0.0 milestone May 17, 2025
Pierre-Sassoulas added a commit that referenced this pull request Aug 9, 2025
…10487)

* [ci] Install pylint before every test (#10388) (#10389)

Co-authored-by: Marc Mueller <[email protected]>

* Improve backport job permissions (#10390) (#10391)

(cherry picked from commit 222ab20)

* Resolve `possibly-used-before-assignment` false positives from `match` block assignments (#10393)

(cherry picked from commit ad14b5b)

* Use custom Github App to authenticate backport job (#10394) (#10396)

(cherry picked from commit 6be8676)

Co-authored-by: Marc Mueller <[email protected]>

* Fix Pyreverse: Aggregations aren't filtered according to filter mode (PUB_ONLY, etc.) (#10379) (#10401)

* updated diagrams.py file

* added tests

* updated tests

* added test cases

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------


(cherry picked from commit ed59632)

Co-authored-by: pavan-msys <[email protected]>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>

* Fix Mermaid printer rendering double underscores as bold formatting (#10403) (#10410)

(cherry picked from commit 25a0f9e)

Co-authored-by: Julian Grimm <[email protected]>
Co-authored-by: Pierre Sassoulas <[email protected]>

* Respect docstring-min-length in docparams extension (#10104) (#10434)

(cherry picked from commit 7f5e996)

Co-authored-by: Berker ŞAL <[email protected]>

* Fix `unused-variable` false positive when using same name for multiple exceptions (#10436) (#10481)

(cherry picked from commit 9e72867)

Co-authored-by: Zen Lee <[email protected]>

* Fix false-negative for used-before-assignment with postponed evaluation in function defs (#10482) (#10483)

(cherry picked from commit d363fca)

Co-authored-by: Marc Mueller <[email protected]>

* Update pytest-benchmark requirement from ~=4.0 to ~=5.1 (#10066) (#10484)

(cherry picked from commit f04761b)

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump pylint to 3.3.8, update changelog (#10486)

---------

Co-authored-by: Marc Mueller <[email protected]>
Co-authored-by: Jacob Walls <[email protected]>
Co-authored-by: pylint-backport-bot[bot] <212256041+pylint-backport-bot[bot]@users.noreply.github.com>
Co-authored-by: pavan-msys <[email protected]>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Julian Grimm <[email protected]>
Co-authored-by: Berker ŞAL <[email protected]>
Co-authored-by: Zen Lee <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport maintenance/3.3.x Maintenance Discussion or action around maintaining pylint or the dev workflow Skip news 🔇 This change does not require a changelog entry
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants