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

[Examples] Check key exists in datasets first #11503

Merged
merged 1 commit into from May 9, 2021

Conversation

oToToT
Copy link
Contributor

@oToToT oToToT commented Apr 29, 2021

What does this PR do?

Correctly check the key exists before accessing it in some example scripts. I guess this is probably a mistake when writing example scripts.

Before submitting

  • This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
  • Did you read the contributor guideline, Pull Request section?
  • Was this discussed/approved via a Github issue or the forum? Please add a link
    to it if that's the case.
  • Did you make sure to update the documentation with your changes? Here are the
    documentation guidelines, and
    here are tips on formatting docstrings.
  • Did you write any new necessary tests?

No tests since I didn't see any tests related to examples. Maybe someone could point it out for me.

Who can review?

Anyone in the community is free to review the PR once the tests have passed. Feel free to tag
members/contributors who may be interested in your PR.

Probably @bhadreshpsavani would like to review this according to the log from git blame.
Or @sgugger, @patil-suraj as this is about examples.

@bhadreshpsavani
Copy link
Contributor

bhadreshpsavani commented Apr 29, 2021

Hi @oToToT,
Thanks for the PR, The changes seem valid to me. It should be as per changes in this PR.
@sgugger what's your view on these changes?

Copy link
Collaborator

@sgugger sgugger left a comment

Choose a reason for hiding this comment

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

Thanks for fixing, it's better this way indeed!

@oToToT
Copy link
Contributor Author

oToToT commented May 9, 2021

Hi, @sgugger
I'm not familiar with how huggingface do with pull requests, did I miss something to make it be merged?
Or I just need to stay and wait it.

Thanks!

@sgugger
Copy link
Collaborator

sgugger commented May 9, 2021

Thanks for the ping! I just forgot to click the merge button 🤦

@sgugger sgugger merged commit f2ffcaf into huggingface:master May 9, 2021
@oToToT oToToT deleted the check-datasets-key branch May 9, 2021 19:48
Iwontbecreative pushed a commit to Iwontbecreative/transformers that referenced this pull request Jul 15, 2021
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.

None yet

3 participants