Skip to content

2856 refactor dataframe helper out of compliance test helper#2951

Merged
amc-corey-cox merged 5 commits into
mainfrom
2856-pandera-compliance-helper
Nov 18, 2025
Merged

2856 refactor dataframe helper out of compliance test helper#2951
amc-corey-cox merged 5 commits into
mainfrom
2856-pandera-compliance-helper

Conversation

@tfliss

@tfliss tfliss commented Oct 17, 2025

Copy link
Copy Markdown
Contributor

This is part of a group of PRs that implement multiple generation targets
in the Pandera dataframe generator. #2975
This is to enable PolaRS support #2856.
(see the description of 2856 for the full list of PRs)

The main tests to re-run on the specific functionality are:
uv run pytest -s -vv --cli-log-level=INFO -m panderagen tests/test_compliance/

This PR specifically:

  • refactors the check_data_pandera() function mostly verbatim out of helper.py in the test_compliance suite.
  • adds a skip-list that will call pytest skip list if the schema name starts with a list entry.
  • parametrizes the importerskip version for pandera that was hardcoded to 1.0
  • adds a backing-form parameter to the panderagen constructor that is used in helper.py (to simplify next PR in the series)
  • panderagen.py also had a few ruff fixes that I previously missed.

Note that the logic in check_data_pandera() will be improved in a future PR in this series once the PolaRS schema generator is enabled. A few additional inlining tests will also be skipped until that time.

@tfliss tfliss linked an issue Oct 17, 2025 that may be closed by this pull request
@codecov

codecov Bot commented Oct 17, 2025

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 84.00%. Comparing base (023fa14) to head (1dc983e).
⚠️ Report is 6 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2951      +/-   ##
==========================================
+ Coverage   80.30%   84.00%   +3.69%     
==========================================
  Files         147      147              
  Lines       15988    15990       +2     
  Branches     3234     3234              
==========================================
+ Hits        12839    13432     +593     
+ Misses       2478     1842     -636     
- Partials      671      716      +45     

☔ 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.

@tfliss tfliss marked this pull request as ready for review November 18, 2025 18:35
Base automatically changed from 2856-pandera-render-adapters to main November 18, 2025 22:02

@amc-corey-cox amc-corey-cox left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This looks good. I mentioned something about the skip list but I don't think it needs to hold up the merge but do please get back to me with a response on that.

"test_cardinality-ClassNameEQ_C__SlotNameEQ_sSPACE1__TypeNameEQ_tSPACE1",
"test_cardinality-ClassNameEQ_C__SlotNameEQ_1s__TypeNameEQ_T1",
"test_cardinality-ClassNameEQ_C__SlotNameEQ_1s__TypeNameEQ_T1",
]

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Are we skipping these because they are not implemented or unnecessary? Will we be dealing with these later somehow?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I think those tests fail because I need to improve slot name handling in edge cases, so not addressed in these PRs, but I may have a fix in work-in-progress code.

I'm moving toward tracking the skip list here rather than touching many individual test/test_compliance/*.py files just to skip or not skip individual tests while a generator is under development. Very open to suggestions or questions on this approach.

Most of the other tests that are turned off in this PR that deal with inlining will be re-enabled by the end of these PRs, expanding the functionality overall.

@amc-corey-cox amc-corey-cox merged commit 093800f into main Nov 18, 2025
23 checks passed
@amc-corey-cox amc-corey-cox deleted the 2856-pandera-compliance-helper branch November 18, 2025 22:38
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.

Support multiple dataframe formats with pandera genrator

2 participants