Skip to content

Conversation

R-Palazzo
Copy link
Contributor

Resolve #2682
CU-86b6wkybp

@R-Palazzo R-Palazzo self-assigned this Oct 6, 2025
@R-Palazzo R-Palazzo requested a review from a team as a code owner October 6, 2025 15:02
@sdv-team
Copy link
Contributor

sdv-team commented Oct 6, 2025

@R-Palazzo R-Palazzo removed the request for review from a team October 6, 2025 15:02
if _is_datetime_type(sequence_index[self._sequence_index]):
sequence_index[self._sequence_index] = cast_to_datetime64(
sequence_index[self._sequence_index]
).astype(np.int64)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Before pandas 2.2, datetime columns stored as object dtypes were silently converted to float dtype. To be consistent with the fill_value used in L330 or L332, the column has to be numerical.

Let me know if this makes sense

Copy link

codecov bot commented Oct 6, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.00%. Comparing base (ae6e1c0) to head (c2e8215).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2707   +/-   ##
=======================================
  Coverage   97.00%   97.00%           
=======================================
  Files          74       74           
  Lines        7770     7776    +6     
=======================================
+ Hits         7537     7543    +6     
  Misses        233      233           
Flag Coverage Δ
unit 97.00% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Comment on lines 323 to 325
diff_series = sequence_index.groupby(self._sequence_key, group_keys=False)[
self._sequence_index
].transform(lambda s: s.diff().bfill())
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we not use lambda here and have a function instead ?

@R-Palazzo R-Palazzo force-pushed the issue-2682-pandas-warning branch from 12c9076 to 01d9a0f Compare October 10, 2025 12:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

PARSynthesizer: FutureWarnings in groupby.apply and Series.__getitem__ from pandas

4 participants