Skip to content

Commit

Permalink
passing FileTimerRequests.to_json() to log_debug_info_for_expired_tim…
Browse files Browse the repository at this point in the history
…ers for a better debugging experience (pytorch#135913)

Summary: The change involves passing the expired timers to the log_debug_info_for_expired_timers function after to_json() has been applied . This change is made to provide a better debugging experience for the user.

Test Plan: unit tests

Reviewed By: gag1jain

Differential Revision: D62408767

Pull Request resolved: pytorch#135913
Approved by: https://github.com/gag1jain
  • Loading branch information
felixsu2006 authored and Chao1Han committed Sep 20, 2024
1 parent fa5087b commit c9d6bb8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion torch/distributed/elastic/timer/file_based_local_timer.py
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ def _run_watchdog(self, fd: io.TextIOWrapper) -> None:
log_debug_info_for_expired_timers(
self._run_id,
{
pid: self._get_scopes(expired_timers)
pid: [expired_timer.to_json() for expired_timer in expired_timers]
for pid, expired_timers in all_expired_timers.items()
},
)
Expand Down

0 comments on commit c9d6bb8

Please sign in to comment.