Skip to content

Commit 7fdb244

Browse files
tchatonlexierule
authored andcommitted
Resolve increased time. (#14074)
(cherry picked from commit 55ae812)
1 parent 1ac3480 commit 7fdb244

File tree

3 files changed

+4
-1
lines changed

3 files changed

+4
-1
lines changed

src/lightning_app/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
1515

1616
- Resolved a bug where the work statuses will grow quickly and be duplicated ([#13970](https://github.com/Lightning-AI/lightning/pull/13970))
1717

18+
- Resolved a bug about a race condition when sending the work state through the caller_queue ([#14074](https://github.com/Lightning-AI/lightning/pull/14074))
19+
1820

1921

2022
## [0.5.4] - 2022-08-01

src/lightning_app/utilities/proxies.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ def _send_data_to_caller_queue(work: "LightningWork", caller_queue: "BaseQueue",
7373

7474
data.update({"state": work_state})
7575
logger.debug(f"Sending to {work.name}: {data}")
76-
caller_queue.put(data)
76+
caller_queue.put(deepcopy(data))
7777

7878
# Reset the calls entry.
7979
work_state["calls"] = calls

tests/tests_app/core/test_lightning_app.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -896,6 +896,7 @@ def __init__(self, **kwargs):
896896

897897
def run(self, signal: int):
898898
self.counter += 1
899+
assert len(self._calls) == 2
899900

900901

901902
class SizeFlow(LightningFlow):

0 commit comments

Comments
 (0)