Issue 41747: dataclasses: generated method's using the wrong qualname
Issue41747
Created on 2020-09-08 20:38 by BTaskaya, last changed 2022-04-11 14:59 by admin. This issue is now closed.
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 22155 | merged | BTaskaya, 2020-09-08 20:42 | |
| Messages (3) | |||
|---|---|---|---|
| msg376594 - (view) | Author: Batuhan Taskaya (BTaskaya) * ![]() |
Date: 2020-09-08 20:38 | |
$ cat t.py
from dataclasses import dataclass
@dataclass
class Foo:
bar: int
Foo()
$ python t.py
Traceback (most recent call last):
File "/home/isidentical/cpython/cpython/t.py", line 7, in <module>
Foo()
TypeError: __create_fn__.<locals>.__init__() missing 1 required positional argument: 'bar'
|
|||
| msg379208 - (view) | Author: Eric V. Smith (eric.smith) * ![]() |
Date: 2020-10-21 13:49 | |
New changeset c7437e2c0216e05fbf17bf96294cb20954e36e48 by Batuhan Taskaya in branch 'master': bpo-41747: Ensure all dataclass methods uses their parents' qualname (GH-22155) https://github.com/python/cpython/commit/c7437e2c0216e05fbf17bf96294cb20954e36e48 |
|||
| msg379209 - (view) | Author: Eric V. Smith (eric.smith) * ![]() |
Date: 2020-10-21 13:50 | |
Thanks for the PR! |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022-04-11 14:59:35 | admin | set | github: 85913 |
| 2020-10-21 13:50:18 | eric.smith | set | status: open -> closed resolution: fixed messages: + msg379209 stage: patch review -> resolved |
| 2020-10-21 13:49:30 | eric.smith | set | messages: + msg379208 |
| 2020-09-09 01:43:30 | rhettinger | set | assignee: eric.smith |
| 2020-09-08 20:42:52 | BTaskaya | set | keywords:
+ patch stage: patch review pull_requests: + pull_request21234 |
| 2020-09-08 20:38:57 | BTaskaya | create | |
