Skip to content

Commit b10cef2

Browse files
tarikkicarltongibson
authored andcommitted
Lowered group_send failure logging level from exception to info.
1 parent 572aa94 commit b10cef2

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

CHANGELOG.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ Unreleased
77

88
* Ensured messages are expired even when channel is in constant activity.
99

10-
* Optimized Redis script caching
10+
* Optimized Redis script caching.
11+
12+
* Reduced group_send failure logging level to reduce log noise.
1113

1214

1315
2.4.2 (2020-02-19)

channels_redis/core.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -687,7 +687,7 @@ async def group_send(self, group, message):
687687
group_send_lua, keys=channel_redis_keys, args=args
688688
)
689689
if channels_over_capacity > 0:
690-
logger.exception(
690+
logger.info(
691691
f"{channels_over_capacity} of {len(channel_names)} channels over capacity in group {group}"
692692
)
693693

tests/test_core.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,7 @@ async def test_group_send_capacity(channel_layer, caplog):
356356

357357
# Make sure number of channels over capacity are logged
358358
for record in caplog.records:
359-
assert record.levelname == "ERROR"
359+
assert record.levelname == "INFO"
360360
assert record.msg == "1 of 1 channels over capacity in group test-group"
361361

362362

@@ -396,7 +396,7 @@ async def test_group_send_capacity_multiple_channels(channel_layer, caplog):
396396

397397
# Make sure number of channels over capacity are logged
398398
for record in caplog.records:
399-
assert record.levelname == "ERROR"
399+
assert record.levelname == "INFO"
400400
assert record.msg == "1 of 2 channels over capacity in group test-group"
401401

402402

0 commit comments

Comments
 (0)