Skip to content

Conversation

@albertvillanova
Copy link
Member

@albertvillanova albertvillanova commented May 23, 2022

Since Python 3.8, the typing module:

  • raises an AttributeError when trying to access __args__ on any type, e.g.: List.__args__
  • provides the get_args function instead: get_args(List)

This PR implements a fix for Python >=3.8 whereas maintaining backward compatibility.

@HuggingFaceDocBuilderDev
Copy link

HuggingFaceDocBuilderDev commented May 23, 2022

The documentation is not available anymore as the PR was closed or merged.

Copy link
Member

@lhoestq lhoestq left a comment

Choose a reason for hiding this comment

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

good catch thanks !

@albertvillanova albertvillanova merged commit bd66ece into huggingface:master Jun 1, 2022
@albertvillanova albertvillanova deleted the fix-metadata branch June 1, 2022 09:19
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.

3 participants