Skip to content

fix: Make enums tolerate multiple sequence types #18

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 26, 2025

Conversation

AndreasAlbertQC
Copy link
Collaborator

Motivation

Fixes #17, which actually has nothing to do with parquet. The parquet connection just happened because the enum categories are always a list after going through parquet.

Changes

  • Added list cast to ensure that Enum.categories is always stored as a list internally.
  • Added a test that fails without the fix. @delsner @borchero : I wasn't 100% sure what file the test should be in. Let me know if you think it should go somewhere else.

@AndreasAlbertQC AndreasAlbertQC changed the title 2025 04 25 enum sequence types fix: Make enums tolerate multiple sequence types Apr 25, 2025
@github-actions github-actions bot added the fix label Apr 25, 2025
@AndreasAlbertQC AndreasAlbertQC force-pushed the 2025-04-25-enum-sequence-types branch from 54a79f1 to a47a169 Compare April 25, 2025 16:25
Copy link

codecov bot commented Apr 25, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (3bf3acf) to head (a47a169).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main       #18   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           37        37           
  Lines         1807      1807           
=========================================
  Hits          1807      1807           

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

Copy link
Member

@borchero borchero left a comment

Choose a reason for hiding this comment

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

Ha, weird edge case 👀 thanks for fixing!

@AndreasAlbertQC AndreasAlbertQC merged commit 1e4485e into main Apr 26, 2025
18 checks passed
@AndreasAlbertQC AndreasAlbertQC deleted the 2025-04-25-enum-sequence-types branch April 26, 2025 11:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Roundtripping enums through parquet fails unexpectedly if the enum is defined via a tuple
2 participants