Skip to content

Commit b7056e6

Browse files
rhshadrachgasparitiago
authored andcommitted
CLN: Add comment on catch_warnings in agg_list_like (pandas-dev#43826)
1 parent 82c2787 commit b7056e6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

pandas/core/apply.py

+2
Original file line numberDiff line numberDiff line change
@@ -370,6 +370,8 @@ def agg_list_like(self) -> DataFrame | Series:
370370
# Capture and suppress any warnings emitted by us in the call
371371
# to agg below, but pass through any warnings that were
372372
# generated otherwise.
373+
# This is necessary because of https://bugs.python.org/issue29672
374+
# See GH #43741 for more details
373375
with warnings.catch_warnings(record=True) as record:
374376
new_res = colg.aggregate(arg)
375377
if len(record) > 0:

0 commit comments

Comments
 (0)