Skip to content

Commit

Permalink
Fix matter_yamltests with Python 11 again. (#26464)
Browse files Browse the repository at this point in the history
Due to https://docs.python.org/3.11/whatsnew/3.11.html#dataclasses, the previous
code fails: it's using a mutable class instance as a default values of a
dataclass field.
  • Loading branch information
bzbarsky-apple authored and pull[bot] committed Feb 22, 2024
1 parent c6235ea commit e969d25
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/py_matter_yamltests/matter_yamltests/runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
import asyncio
import time
from abc import ABC, abstractmethod
from dataclasses import dataclass
from dataclasses import dataclass, field

from .adapter import TestAdapter
from .hooks import TestRunnerHooks
Expand Down Expand Up @@ -72,7 +72,7 @@ class TestRunnerConfig:
"""
adapter: TestAdapter = None
pseudo_clusters: PseudoClusters = PseudoClusters([])
options: TestRunnerOptions = TestRunnerOptions()
options: TestRunnerOptions = field(default_factory=TestRunnerOptions)
hooks: TestRunnerHooks = TestRunnerHooks()


Expand Down

0 comments on commit e969d25

Please sign in to comment.