Skip to content

Commit 8d23f62

Browse files
authored
Update module path for LightningDeprecationWarning in setup.cfg (#11793)
1 parent 1b107c5 commit 8d23f62

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

pytorch_lightning/utilities/distributed.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ def register_ddp_comm_hook(
289289
if not _TORCH_GREATER_EQUAL_1_9:
290290
rank_zero_warn("Not applying DDP comm wrapper. To use communication wrapper, please use pytorch>=1.9.0.")
291291
else:
292-
rank_zero_info(
292+
new_rank_zero_info(
293293
f"DDP comm wrapper is provided, apply {ddp_comm_wrapper.__qualname__}({ddp_comm_hook.__qualname__})."
294294
)
295295
ddp_comm_hook = ddp_comm_wrapper(ddp_comm_hook)
@@ -336,7 +336,7 @@ def init_dist_connection(
336336
torch.distributed.init_process_group(torch_distributed_backend, rank=global_rank, world_size=world_size, **kwargs)
337337

338338
# on rank=0 let everyone know training is starting
339-
rank_zero_info(
339+
new_rank_zero_info(
340340
f"{'-' * 100}\n"
341341
f"distributed_backend={torch_distributed_backend}\n"
342342
f"All distributed processes registered. Starting with {world_size} processes\n"

setup.cfg

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,12 @@ addopts =
2626
--disable-pytest-warnings
2727
filterwarnings =
2828
# error out on our deprecation warnings - ensures the code and tests are kept up-to-date
29-
error::pytorch_lightning.utilities.warnings.LightningDeprecationWarning
29+
error::pytorch_lightning.utilities.rank_zero.LightningDeprecationWarning
3030
error::FutureWarning
3131
# warnings from deprecated modules on import
3232
# TODO: remove in 1.7
33-
ignore::pytorch_lightning.utilities.warnings.LightningDeprecationWarning:pytorch_lightning.core.decorators
34-
ignore::pytorch_lightning.utilities.warnings.LightningDeprecationWarning:pytorch_lightning.core.memory
33+
ignore::pytorch_lightning.utilities.rank_zero.LightningDeprecationWarning:pytorch_lightning.core.decorators
34+
ignore::pytorch_lightning.utilities.rank_zero.LightningDeprecationWarning:pytorch_lightning.core.memory
3535

3636
junit_duration_report = call
3737

0 commit comments

Comments
 (0)