Use slots in TraceElement (#95877)

This commit is contained in:
J. Nick Koston 2023-07-05 01:44:00 -05:00 committed by GitHub
parent 659281aab6
commit 1dfa2f3c6b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -17,6 +17,17 @@ from .typing import TemplateVarsType
class TraceElement:
"""Container for trace data."""
__slots__ = (
"_child_key",
"_child_run_id",
"_error",
"path",
"_result",
"reuse_by_child",
"_timestamp",
"_variables",
)
def __init__(self, variables: TemplateVarsType, path: str) -> None:
"""Container for trace data."""
self._child_key: str | None = None