Bug report
Bug description:
import pickle
import sys
from dataclasses import dataclass, field
@dataclass
class State:
x: list[int] = field(default_factory=list)
print(pickle.dumps(State([0])))
The following code will run successfully on it's own, but will fail if run with cProfile, with the message that __main__.State could not be found by.
CPython versions tested on:
CPython main branch
Operating systems tested on:
Linux
Linked PRs
Bug report
Bug description:
The following code will run successfully on it's own, but will fail if run with
cProfile, with the message that__main__.Statecould not be found by.CPython versions tested on:
CPython main branch
Operating systems tested on:
Linux
Linked PRs