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

Allow columns option to be more generic type than list (Fixes #389) #390

Merged
merged 2 commits into from
May 20, 2024

Conversation

rbubley
Copy link
Contributor

@rbubley rbubley commented May 20, 2024

Description

Convert columns parameter to a list prior to checking it is identical to a sorted list, so it will now work, e.g. with a tuple.
Changed the type hint from Iterable to Sequence to reflect the fact that that it must have a consistent order. (Sequence doesn't formally guarantee this, but it is implicit in the definition.)

Motivation and Context

Fixes issue #389.

How Has This Been Tested?

nox has been run. Although errors were found, these were the same errors as in master, and were unrelated to this change.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Checklist:

  • I read the contributing document.
  • My code follows the code style of this project with running linter.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.

Copy link
Owner

@chezou chezou left a comment

Choose a reason for hiding this comment

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

Overall looks good. Can you add a unit test to check tuple passing?

@chezou chezou merged commit 79792ad into chezou:master May 20, 2024
@chezou
Copy link
Owner

chezou commented May 20, 2024

@rbubley Thank you for your quick response! I'll release new patch version.

@chezou
Copy link
Owner

chezou commented May 20, 2024

chezou added a commit that referenced this pull request May 21, 2024
@chezou chezou mentioned this pull request May 21, 2024
7 tasks
chezou added a commit that referenced this pull request May 21, 2024
@chezou
Copy link
Owner

chezou commented May 21, 2024

Okay, released v2.9.3 to include all type hint fixes.

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