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

457-fetch-without-hidden-worksheets #1207

Merged
merged 5 commits into from
Jun 7, 2023

Conversation

alifeee
Copy link
Collaborator

@alifeee alifeee commented Jun 6, 2023

add exclude_hidden kwarg to gspread.Spreadsheet.worksheets(), so you can fetch only non-hidden sheets

closes #457

@alifeee alifeee marked this pull request as draft June 6, 2023 01:44
@alifeee
Copy link
Collaborator Author

alifeee commented Jun 6, 2023

Marked as draft. Might change exclude_hidden to include_hidden (with opposite behaviour), as I think it is more clear(?)

@lavigne958
Copy link
Collaborator

Thank you for this awesome feature !

Regarding the extra parameter: that is a good question. In both cases when users will update their code to skip hidden sheets they will need to change the default value anyway, so no option is better than the other to me.

  • in exlude_hidden, as a user I now don't want them so I will update my code to use the new parameter set to True
  • in include_hidden, as a user I now don't want them so I will update my code to use the new parameter set to False
    Both cases the interest of the new feature will require update from users, so I would go for the first one you propose exclude_hidden just because usually in the computer 💻 world 🌍 we tend to exclude thing 🤔

@alifeee
Copy link
Collaborator Author

alifeee commented Jun 6, 2023

Hm, yes. I will leave it as is. Plus, then I don't have to make more commits...

@alifeee alifeee marked this pull request as ready for review June 6, 2023 22:05
Copy link
Collaborator

@lavigne958 lavigne958 left a comment

Choose a reason for hiding this comment

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

Agreed, let's go for merge.

@lavigne958 lavigne958 merged commit b9c5e7d into master Jun 7, 2023
@alifeee alifeee deleted the 457-fetch-without-hidden-worksheets branch June 7, 2023 13:00
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.

Ability to distinguish between normal worksheets and hidden worksheets?
2 participants