mirror of
https://github.com/home-assistant/core.git
synced 2025-04-26 02:07:54 +00:00
Copy instead of deepcopy the variables in a wait for trigger (#39796)
This commit is contained in:
parent
5bcffba53e
commit
63aa46369b
@ -1,6 +1,5 @@
|
|||||||
"""Helpers to execute scripts."""
|
"""Helpers to execute scripts."""
|
||||||
import asyncio
|
import asyncio
|
||||||
from copy import deepcopy
|
|
||||||
from datetime import datetime, timedelta
|
from datetime import datetime, timedelta
|
||||||
from functools import partial
|
from functools import partial
|
||||||
import itertools
|
import itertools
|
||||||
@ -572,7 +571,7 @@ class _ScriptRun:
|
|||||||
"" if delay is None else f" (timeout: {timedelta(seconds=delay)})",
|
"" if delay is None else f" (timeout: {timedelta(seconds=delay)})",
|
||||||
)
|
)
|
||||||
|
|
||||||
variables = deepcopy(self._variables)
|
variables = {**self._variables}
|
||||||
self._variables["wait"] = {"remaining": delay, "trigger": None}
|
self._variables["wait"] = {"remaining": delay, "trigger": None}
|
||||||
|
|
||||||
async def async_done(variables, context=None):
|
async def async_done(variables, context=None):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user