Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 34k
bpo-36517: Raise error on multiple inheritance with NamedTuple#19363
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
serhiy-storchaka merged 2 commits into python:master from serhiy-storchaka:typing-namedtuple-no-multiple-inheritanceApr 4, 2020
Merged
bpo-36517: Raise error on multiple inheritance with NamedTuple #19363
serhiy-storchaka merged 2 commits into python:master from serhiy-storchaka:typing-namedtuple-no-multiple-inheritanceApr 4, 2020
Uh oh!
There was an error while loading. Please reload this page.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Member
serhiy-storchaka commented Apr 4, 2020 • edited by bedevere-bot
Loading Uh oh!
There was an error while loading. Please reload this page.
edited by bedevere-bot
Uh oh!
There was an error while loading. Please reload this page.
ilevkivskyi approved these changes Apr 4, 2020
Member
ilevkivskyi left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, LG!
Misc/NEWS.d/next/Library/2020-04-04-17-49-39.bpo-36517.Ilj1IJ.rst Outdated Show resolvedHide resolved
Uh oh!
There was an error while loading. Please reload this page.
Co-Authored-By: Ivan Levkivskyi <[email protected]>
1 task
9 tasks
nhuet added a commit to nhuet/scikit-decide that referenced this pull request May 12, 2022
The error traceback: /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/site-packages/discrete_optimization/tsp/tsp_model.py:267: in <module> class Point2D(Point, NamedTuple): /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/typing.py:1929: in _namedtuple_mro_entries raise TypeError("Multiple inheritance with NamedTuple is not supported") E TypeError: Multiple inheritance with NamedTuple is not supported Coming from python/cpython#19363 Potential solution: replace NamedTuple by Dataclass(frozen=True)nhuet added a commit to nhuet/scikit-decide that referenced this pull request May 12, 2022
The error traceback: /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/site-packages/discrete_optimization/tsp/tsp_model.py:267: in <module> class Point2D(Point, NamedTuple): /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/typing.py:1929: in _namedtuple_mro_entries raise TypeError("Multiple inheritance with NamedTuple is not supported") E TypeError: Multiple inheritance with NamedTuple is not supported Coming from python/cpython#19363 Potential solution: replace NamedTuple by Dataclass(frozen=True)nhuet added a commit to nhuet/scikit-decide that referenced this pull request May 13, 2022
The error traceback: /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/site-packages/discrete_optimization/tsp/tsp_model.py:267: in <module> class Point2D(Point, NamedTuple): /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/typing.py:1929: in _namedtuple_mro_entries raise TypeError("Multiple inheritance with NamedTuple is not supported") E TypeError: Multiple inheritance with NamedTuple is not supported Coming from python/cpython#19363 Potential solution: replace NamedTuple by Dataclass(frozen=True)nhuet added a commit to nhuet/discrete-optimization that referenced this pull request Jun 27, 2022
The error traceback: /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/site-packages/discrete_optimization/tsp/tsp_model.py:267: in <module> class Point2D(Point, NamedTuple): /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/typing.py:1929: in _namedtuple_mro_entries raise TypeError("Multiple inheritance with NamedTuple is not supported") E TypeError: Multiple inheritance with NamedTuple is not supported Coming from python/cpython#19363 Potential solution: replace NamedTuple by Dataclass(frozen=True)nhuet added a commit to nhuet/discrete-optimization that referenced this pull request Jun 27, 2022
The error traceback: /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/site-packages/discrete_optimization/tsp/tsp_model.py:267: in <module> class Point2D(Point, NamedTuple): /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/typing.py:1929: in _namedtuple_mro_entries raise TypeError("Multiple inheritance with NamedTuple is not supported") E TypeError: Multiple inheritance with NamedTuple is not supported Coming from python/cpython#19363 Potential solution: replace NamedTuple by Dataclass(frozen=True)nhuet added a commit to nhuet/discrete-optimization that referenced this pull request Jun 27, 2022
The error traceback: /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/site-packages/discrete_optimization/tsp/tsp_model.py:267: in <module> class Point2D(Point, NamedTuple): /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/typing.py:1929: in _namedtuple_mro_entries raise TypeError("Multiple inheritance with NamedTuple is not supported") E TypeError: Multiple inheritance with NamedTuple is not supported Coming from python/cpython#19363 Potential solution: replace NamedTuple by Dataclass(frozen=True)nhuet added a commit to nhuet/discrete-optimization that referenced this pull request Jun 27, 2022
The error traceback: /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/site-packages/discrete_optimization/tsp/tsp_model.py:267: in <module> class Point2D(Point, NamedTuple): /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/typing.py:1929: in _namedtuple_mro_entries raise TypeError("Multiple inheritance with NamedTuple is not supported") E TypeError: Multiple inheritance with NamedTuple is not supported Coming from python/cpython#19363 Potential solution: replace NamedTuple by Dataclass(frozen=True)nhuet added a commit to nhuet/discrete-optimization that referenced this pull request Jun 28, 2022
The error traceback: /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/site-packages/discrete_optimization/tsp/tsp_model.py:267: in <module> class Point2D(Point, NamedTuple): /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/typing.py:1929: in _namedtuple_mro_entries raise TypeError("Multiple inheritance with NamedTuple is not supported") E TypeError: Multiple inheritance with NamedTuple is not supported Coming from python/cpython#19363 Potential solution: replace NamedTuple by Dataclass(frozen=True)nhuet added a commit to nhuet/discrete-optimization that referenced this pull request Jun 28, 2022
The error traceback: /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/site-packages/discrete_optimization/tsp/tsp_model.py:267: in <module> class Point2D(Point, NamedTuple): /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/typing.py:1929: in _namedtuple_mro_entries raise TypeError("Multiple inheritance with NamedTuple is not supported") E TypeError: Multiple inheritance with NamedTuple is not supported Coming from python/cpython#19363 Potential solution: replace NamedTuple by Dataclass(frozen=True)nhuet added a commit to nhuet/discrete-optimization that referenced this pull request Jun 28, 2022
The error traceback: /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/site-packages/discrete_optimization/tsp/tsp_model.py:267: in <module> class Point2D(Point, NamedTuple): /opt/hostedtoolcache/Python/3.9.12/x64/lib/python3.9/typing.py:1929: in _namedtuple_mro_entries raise TypeError("Multiple inheritance with NamedTuple is not supported") E TypeError: Multiple inheritance with NamedTuple is not supported Coming from python/cpython#19363 Potential solution: replace NamedTuple by Dataclass(frozen=True)tonio-m added a commit to tonio-m/fsql that referenced this pull request Aug 10, 2022
remove double inheritance with NamedTuple to avoid TypeError, as per python 3.9: python/cpython#19363
gmgunter added a commit to isce-framework/isce3 that referenced this pull request May 1, 2025
This doesn't work in Python >=3.9 until Python 3.11. Multiple inheritance with `NamedTuple` has limited support. See: * python/cpython#19363 * python/cpython#88089 * python/cpython#92027
gmgunter added a commit to isce-framework/isce3 that referenced this pull request Aug 18, 2025
…rid (MCR #90132) (#99) * Add bindings for `GLOBAL_MIN_HEIGHT` and `GLOBAL_MAX_HEIGHT` Expose the C++ constants `isce3::core::GLOBAL_MIN_HEIGHT` and `isce3::core::GLOBAL_MAX_HEIGHT` to Python. * Add function to compute radar grid spanning a geo grid * Simplify radar grid construction by ignoring grid coordinate conventions See the discussion on this comment: https://github-fn.jpl.nasa.gov/isce-3/isce/pull/2097#discussion_r26503 * Un-parameterize `Rectangle` This doesn't work in Python >=3.9 until Python 3.11. Multiple inheritance with `NamedTuple` has limited support. See: * python/cpython#19363 * python/cpython#88089 * python/cpython#92027 * Add `look_side` to be a string * Simplify error messages * Rename inner function to avoid name ambiguity * Fix test regexes * Add test cases for antimeridian and pole crossing * Explain dummy parameter values used in test * Test `get_bounding_rectangle()` with +/-inf * Rename inner function to avoid name ambiguity * Update docstrings * Swap inner/outer loop order * Specify default geo2rdr tolerance * Clarify isce3 projection description
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
https://bugs.python.org/issue36517