Repository navigation
[pyOpenMS][TEST] Pin DeprecationWarning + forwarding of the DataFrame shims (#9460) - #9539
Conversation
… shims (OpenMS#9460) pyopenms.peptide_identifications_to_df() and pyopenms.update_scores_from_df() are deprecated module-level wrappers (pyopenms/_dataframes_compat.py) that forward to PeptideIdentificationList.to_df() / .update_scores_from_df(). The existing dataframe tests call them but never assert the deprecation contract. Adds a test (pandas-importorskip) asserting that each wrapper: - emits a DeprecationWarning naming its replacement (pytest.warns), and - forwards correctly -- peptide_identifications_to_df() matches peps.to_df(), and update_scores_from_df() writes back the same scores as the direct call. Closes the deprecated-alias part of issue OpenMS#9460 Section 2. Verified against the built nanobind bindings (2 passed). Co-Authored-By: Claude Opus 4.8 <[email protected]>
|
Warning Review limit reached
More reviews will be available in 3 seconds. Learn how PR review limits work. Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file). ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@timosachsenberg The following names might be missing from the
Please consider applying the following patch: --- AUTHORS 2026-06-15 17:05:51.224826942 +0000
+++ AUTHORS.new 2026-06-15 17:05:56.460136222 +0000
@@ -23,8 +23,8 @@
- Chirag Dave
- Chris Bauer
- Chris Bielow
- - Christie Mathews
- Christian Ehrlich
+ - Christie Mathews
- Clemens Groepl
- Cornelia Friedle
- Daniel Jameson |
What
Adds a pyOpenMS test (pandas-
importorskip) for the two deprecated module-level DataFrame wrappers inpyopenms/_dataframes_compat.py. For each, it asserts the deprecate-and-forward contract:pyopenms.peptide_identifications_to_df(peps)→ emits aDeprecationWarningnamingto_df, and forwards topeps.to_df()(same shape/columns);pyopenms.update_scores_from_df(peps, df, "Mascot")→ emits aDeprecationWarningnamingupdate_scores_from_df, and forwards the score write-back, matching the direct (non-deprecated)peps.update_scores_from_df(df, "Mascot")call.Why
Closes the deprecated-alias part of the §2 (pyOpenMS nanobind rewrite)
[AUTO]task in the OpenMS 3.6.0 pre-release testing plan (#9460):The general dataframe tests (
test000.py,test_dataframe_columns.py) call these wrappers but only check the resulting frame — theDeprecationWarningitself was never asserted (the oneDeprecationWarningcheck intest_dataframe_columns.pyis forto_arrow(long_format=…), a different alias). This pins the warning + forwarding directly.Test plan
Tests only — no production code changed. Verified against the built nanobind bindings two ways: run as a direct script (
All deprecated-dataframe-shim tests passed!) and viapytest(2 passed). pandas-importorskipkeeps it optional; the classes used live in themetadata/chemistry/kernelmodules (unaffected by the unrelated stale-build_pyopenms_analysiswarning).Part of #9460. Follows #9524, #9525, #9526, #9528, #9530, #9531, #9532, #9533, #9534, #9535, #9536, #9537, #9538.
🤖 Generated with Claude Code