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

Upgrade astroid to 2.13.2 #8030

Merged
merged 1 commit into from
Jan 13, 2023

Conversation

Pierre-Sassoulas
Copy link
Member

No description provided.

@Pierre-Sassoulas Pierre-Sassoulas added Maintenance Discussion or action around maintaining pylint or the dev workflow Skip news 🔇 This change does not require a changelog entry labels Jan 7, 2023
@Pierre-Sassoulas Pierre-Sassoulas added this to the 2.16.0 milestone Jan 7, 2023
@codecov
Copy link

codecov bot commented Jan 7, 2023

Codecov Report

Merging #8030 (c10ad13) into main (e487a46) will decrease coverage by 0.00%.
The diff coverage is n/a.

❗ Current head c10ad13 differs from pull request most recent head c96caed. Consider uploading reports for the commit c96caed to get more accurate results

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #8030      +/-   ##
==========================================
- Coverage   95.43%   95.42%   -0.01%     
==========================================
  Files         176      176              
  Lines       18545    18525      -20     
==========================================
- Hits        17698    17678      -20     
  Misses        847      847              
Impacted Files Coverage Δ
pylint/checkers/utils.py 95.33% <0.00%> (-0.01%) ⬇️
pylint/checkers/variables.py 97.37% <0.00%> (-0.01%) ⬇️
pylint/extensions/magic_value.py 100.00% <0.00%> (ø)

@github-actions

This comment has been minimized.

@Pierre-Sassoulas
Copy link
Member Author

@nelfin look at the primer result, there's a bunch of false positives that were fixed by your implementation support for is None :)

Copy link
Collaborator

@DanielNoord DanielNoord left a comment

Choose a reason for hiding this comment

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

@Pierre-Sassoulas Pierre-Sassoulas changed the title Upgrade astroid to 2.13.0 Upgrade astroid to 2.13.1 Jan 8, 2023
@github-actions

This comment has been minimized.

@Pierre-Sassoulas Pierre-Sassoulas changed the title Upgrade astroid to 2.13.1 Upgrade astroid to 2.13.2 Jan 8, 2023
Fokko added a commit to Fokko/iceberg that referenced this pull request Jan 8, 2023
It is an issue in a downstream dependency, and is currently being
fixed in pylint: pylint-dev/pylint#8030

Has been fixed in Astroid in:
pylint-dev/astroid#1944
Fokko added a commit to Fokko/iceberg that referenced this pull request Jan 8, 2023
It is an issue in a downstream dependency, and is currently being
fixed in pylint: pylint-dev/pylint#8030

Has been fixed in Astroid in:
pylint-dev/astroid#1944
rdblue pushed a commit to apache/iceberg that referenced this pull request Jan 8, 2023
It is an issue in a downstream dependency, and is currently being
fixed in pylint: pylint-dev/pylint#8030

Has been fixed in Astroid in:
pylint-dev/astroid#1944
@github-actions

This comment has been minimized.

@Pierre-Sassoulas
Copy link
Member Author

Pierre-Sassoulas commented Jan 9, 2023

The new import-error in psycopg, no-name-in-module in coverage and no-memberin sentry might be a regression caused by astroid import system ? @jacobtylerwalls what do you think ? (Everything else seems like false positive removed by support for is None in inferance)

@DanielNoord
Copy link
Collaborator

Changes look good except for the import indeed.

@Pierre-Sassoulas Pierre-Sassoulas added the Needs investigation 🔬 A bug or crash where it's not immediately obvious what is happenning label Jan 9, 2023
@jacobtylerwalls
Copy link
Member

jacobtylerwalls commented Jan 13, 2023

I tried to reproduce the psycopg error outside the primer and couldn't (but I was in a rush). I'm not certain the way the primer packages are packaged all together under a single directory is realistic--I remember opening an issue about primer packages polluting each other. I'm still interested to try for a reproducer, but I don't know that I'll have time this weekend.

@DanielNoord
Copy link
Collaborator

@Pierre-Sassoulas Let's merge then and get some real world examples (if there are any) from the beta.

@Pierre-Sassoulas Pierre-Sassoulas removed the Needs investigation 🔬 A bug or crash where it's not immediately obvious what is happenning label Jan 13, 2023
@Pierre-Sassoulas
Copy link
Member Author

Let's release the beta in the wild and see how it fare then :D

@Pierre-Sassoulas Pierre-Sassoulas enabled auto-merge (squash) January 13, 2023 08:52
@github-actions
Copy link
Contributor

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

Effect on astroid:
The following messages are now emitted:

  1. useless-suppression:
    Useless suppression of 'not-callable'
    https://github.com/PyCQA/astroid/blob/9eb8c47ddb6b48e14dbdb87bb1b02fcb580cb20d/astroid/nodes/node_ng.py#L160

The following messages are no longer emitted:

  1. suppressed-message:
    Suppressed 'not-callable' (from line 160)
    https://github.com/PyCQA/astroid/blob/9eb8c47ddb6b48e14dbdb87bb1b02fcb580cb20d/astroid/nodes/node_ng.py#L161

Effect on django:
The following messages are no longer emitted:

  1. unsubscriptable-object:
    Value 'self.related_ids' is unsubscriptable
    https://github.com/django/django/blob/648005dee62481acc1784e5c9625e90f0fd6aab4/django/db/models/sql/subqueries.py#L137
  2. bad-string-format-type:
    Argument 'builtins.NoneType' does not match format type 'd'
    https://github.com/django/django/blob/648005dee62481acc1784e5c9625e90f0fd6aab4/django/utils/translation/template.py#L167
  3. invalid-unary-operand-type:
    bad operand type for unary -: NoneType
    https://github.com/django/django/blob/648005dee62481acc1784e5c9625e90f0fd6aab4/django/forms/fields.py#L436

Effect on flask:
The following messages are no longer emitted:

  1. not-callable:
    request_close is not callable
    https://github.com/pallets/flask/blob/9da947a279d5ed5958609e0b6ec690160c496480/src/flask/ctx.py#L403

Effect on music21:
The following messages are now emitted:

  1. useless-suppression:
    Useless suppression of 'unpacking-non-sequence'
    https://github.com/cuthbertLab/music21/blob/323523633d9e35cee96c825fa1b216333ef38351/music21/abcFormat/__init__.py#L1663

The following messages are no longer emitted:

  1. suppressed-message:
    Suppressed 'unpacking-non-sequence' (from line 1663)
    https://github.com/cuthbertLab/music21/blob/323523633d9e35cee96c825fa1b216333ef38351/music21/abcFormat/__init__.py#L1663

Effect on pandas:
The following messages are no longer emitted:

  1. invalid-unary-operand-type:
    bad operand type for unary -: str
    https://github.com/pandas-dev/pandas/blob/ad91ead6de5d6b90747b10d365ba758dbbfd95a4/pandas/tests/arithmetic/test_timedelta64.py#L781
  2. invalid-unary-operand-type:
    bad operand type for unary -: str
    https://github.com/pandas-dev/pandas/blob/ad91ead6de5d6b90747b10d365ba758dbbfd95a4/pandas/tests/arithmetic/test_timedelta64.py#L790
  3. invalid-unary-operand-type:
    bad operand type for unary ~: NoneType
    https://github.com/pandas-dev/pandas/blob/ad91ead6de5d6b90747b10d365ba758dbbfd95a4/pandas/core/arrays/masked.py#L689
  4. invalid-unary-operand-type:
    bad operand type for unary ~: NoneType
    https://github.com/pandas-dev/pandas/blob/ad91ead6de5d6b90747b10d365ba758dbbfd95a4/pandas/core/arrays/masked.py#L696
  5. invalid-unary-operand-type:
    bad operand type for unary ~: NoneType
    https://github.com/pandas-dev/pandas/blob/ad91ead6de5d6b90747b10d365ba758dbbfd95a4/pandas/core/tools/numeric.py#L215

Effect on psycopg:
The following messages are now emitted:

  1. import-error:
    Unable to import 'psycopg'
    https://github.com/psycopg/psycopg/blob/ea5ff3d55d6054398c26e6da298cff745e0d38c5/psycopg/psycopg/__init__.py#L9
  2. import-error:
    Unable to import 'psycopg'
    https://github.com/psycopg/psycopg/blob/ea5ff3d55d6054398c26e6da298cff745e0d38c5/psycopg/psycopg/__init__.py#L10
  3. import-error:
    Unable to import 'psycopg'
    https://github.com/psycopg/psycopg/blob/ea5ff3d55d6054398c26e6da298cff745e0d38c5/psycopg/psycopg/__init__.py#L11
  4. import-error:
    Unable to import 'psycopg'
    https://github.com/psycopg/psycopg/blob/ea5ff3d55d6054398c26e6da298cff745e0d38c5/psycopg/psycopg/__init__.py#L29
  5. import-error:
    Unable to import 'psycopg.pq'
    https://github.com/psycopg/psycopg/blob/ea5ff3d55d6054398c26e6da298cff745e0d38c5/psycopg/psycopg/pq/__init__.py#L16
  6. import-error:
    Unable to import 'psycopg.pq'
    https://github.com/psycopg/psycopg/blob/ea5ff3d55d6054398c26e6da298cff745e0d38c5/psycopg/psycopg/pq/__init__.py#L89

Effect on pytest:
The following messages are no longer emitted:

  1. unsubscriptable-object:
    Value 'location' is unsubscriptable
    https://github.com/pytest-dev/pytest/blob/3ad4344656e8abe95d5b86cd83087836ae9cdaa5/src/_pytest/nodes.py#L519
  2. unsubscriptable-object:
    Value 'self.cached_result' is unsubscriptable
    https://github.com/pytest-dev/pytest/blob/3ad4344656e8abe95d5b86cd83087836ae9cdaa5/src/_pytest/fixtures.py#L1061
  3. unsubscriptable-object:
    Value 'self.cached_result' is unsubscriptable
    https://github.com/pytest-dev/pytest/blob/3ad4344656e8abe95d5b86cd83087836ae9cdaa5/src/_pytest/fixtures.py#L1063
  4. unsubscriptable-object:
    Value 'self.cached_result' is unsubscriptable
    https://github.com/pytest-dev/pytest/blob/3ad4344656e8abe95d5b86cd83087836ae9cdaa5/src/_pytest/fixtures.py#L1064
  5. unsubscriptable-object:
    Value 'self.cached_result' is unsubscriptable
    https://github.com/pytest-dev/pytest/blob/3ad4344656e8abe95d5b86cd83087836ae9cdaa5/src/_pytest/fixtures.py#L1067

Effect on sentry:
The following messages are no longer emitted:

  1. no-member:
    Generator 'generator' has no 'enter' member
    https://github.com/getsentry/sentry/blob/f1e1642d46ee4ee3a74cbce961a3e47406a68f0b/src/sentry/models/file.py#L214
  2. no-member:
    Generator 'generator' has no 'exit' member
    https://github.com/getsentry/sentry/blob/f1e1642d46ee4ee3a74cbce961a3e47406a68f0b/src/sentry/models/file.py#L216
  3. no-member:
    Generator 'generator' has no 'enter' member
    https://github.com/getsentry/sentry/blob/f1e1642d46ee4ee3a74cbce961a3e47406a68f0b/src/sentry/utils/pytest/fixtures.py#L442
  4. no-member:
    Generator 'generator' has no 'exit' member
    https://github.com/getsentry/sentry/blob/f1e1642d46ee4ee3a74cbce961a3e47406a68f0b/src/sentry/utils/pytest/fixtures.py#L444

Effect on coverage:
The following messages are no longer emitted:

  1. no-name-in-module:
    No name 'TConfigSectionIn' in module 'coverage.types'
    https://github.com/nedbat/coveragepy/blob/ff554c16cdf23dd8c263e23fdbda51bdb4f4526e/coverage/control.py#L49
  2. no-name-in-module:
    No name 'TConfigValueIn' in module 'coverage.types'
    https://github.com/nedbat/coveragepy/blob/ff554c16cdf23dd8c263e23fdbda51bdb4f4526e/coverage/control.py#L49
  3. no-name-in-module:
    No name 'TConfigValueOut' in module 'coverage.types'
    https://github.com/nedbat/coveragepy/blob/ff554c16cdf23dd8c263e23fdbda51bdb4f4526e/coverage/control.py#L49
  4. no-name-in-module:
    No name 'TConfigSectionOut' in module 'coverage.types'
    https://github.com/nedbat/coveragepy/blob/ff554c16cdf23dd8c263e23fdbda51bdb4f4526e/coverage/tomlconfig.py#L16
  5. no-name-in-module:
    No name 'TConfigValueOut' in module 'coverage.types'
    https://github.com/nedbat/coveragepy/blob/ff554c16cdf23dd8c263e23fdbda51bdb4f4526e/coverage/tomlconfig.py#L16
  6. no-name-in-module:
    No name 'TConfigSectionIn' in module 'coverage.types'
    https://github.com/nedbat/coveragepy/blob/ff554c16cdf23dd8c263e23fdbda51bdb4f4526e/coverage/config.py#L22
  7. no-name-in-module:
    No name 'TConfigValueIn' in module 'coverage.types'
    https://github.com/nedbat/coveragepy/blob/ff554c16cdf23dd8c263e23fdbda51bdb4f4526e/coverage/config.py#L22
  8. no-name-in-module:
    No name 'TConfigSectionOut' in module 'coverage.types'
    https://github.com/nedbat/coveragepy/blob/ff554c16cdf23dd8c263e23fdbda51bdb4f4526e/coverage/config.py#L22
  9. no-name-in-module:
    No name 'TConfigValueOut' in module 'coverage.types'
    https://github.com/nedbat/coveragepy/blob/ff554c16cdf23dd8c263e23fdbda51bdb4f4526e/coverage/config.py#L22
  10. no-name-in-module:
    No name 'TWritable' in module 'coverage.types'
    https://github.com/nedbat/coveragepy/blob/ff554c16cdf23dd8c263e23fdbda51bdb4f4526e/coverage/debug.py#L25

This comment was generated for commit c96caed

@Pierre-Sassoulas Pierre-Sassoulas merged commit bb90b19 into pylint-dev:main Jan 13, 2023
@Pierre-Sassoulas Pierre-Sassoulas deleted the upgrade-astroid branch January 13, 2023 09:49
Fokko added a commit to apache/iceberg-python that referenced this pull request Sep 29, 2023
It is an issue in a downstream dependency, and is currently being
fixed in pylint: pylint-dev/pylint#8030

Has been fixed in Astroid in:
pylint-dev/astroid#1944
Fokko added a commit to apache/iceberg-python that referenced this pull request Sep 30, 2023
It is an issue in a downstream dependency, and is currently being
fixed in pylint: pylint-dev/pylint#8030

Has been fixed in Astroid in:
pylint-dev/astroid#1944
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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.

3 participants