Skip to content
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

FIX: Disallow negative skip_features #312

Merged
merged 2 commits into from
Oct 10, 2023
Merged

Conversation

brendan-ward
Copy link
Member

This sidesteps making a decision around implementing support for negative skip_features in #309 for now and simply disallows that, which would have been equivalent to the behavior prior to #282. We can add support for negative slicing at a different time, if we so choose.

This raises a specific ValueError and expands tests to match. I also added checks for negative max_features and associated tests.

Copy link
Member

@jorisvandenbossche jorisvandenbossche left a comment

Choose a reason for hiding this comment

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

Thanks, +1 on raising a better error message for negative values

pyogrio/tests/test_geopandas_io.py Outdated Show resolved Hide resolved
@brendan-ward brendan-ward merged commit 244b888 into main Oct 10, 2023
15 checks passed
@brendan-ward brendan-ward deleted the no_negative_skip_features branch October 10, 2023 20:12
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.

2 participants