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

Suppress arguments if all system defined TypeVars on py39 #7637

Merged
merged 1 commit into from May 9, 2020

Conversation

tk0miya
Copy link
Member

@tk0miya tk0miya commented May 9, 2020

Feature or Bugfix

  • Bugfix

Purpose

  • It seems the implementation of the typing module has changed since py3.9.0a6+.

  • It causes the following error.

            sig = inspect.signature(f18)
    >       assert stringify_signature(sig) == '(self, arg1: Union[int, Tuple] = 10) -> List[Dict]'
    E       AssertionError: assert '(self, arg1:...Dict[KT, VT]]' == '(self, arg1:...-> List[Dict]'
    E         - (self, arg1: Union[int, Tuple] = 10) -> List[Dict]
    E         + (self, arg1: Union[int, Tuple] = 10) -> List[Dict[KT, VT]]
    E         ?                                                  +++++++ +
    

    https://travis-ci.org/github/sphinx-doc/sphinx/jobs/684582074#L1841-L1846

  • This fixes them with checking arguments are TypeVars on typing module.

@tk0miya tk0miya added this to the 3.1.0 milestone May 9, 2020
@tk0miya tk0miya force-pushed the suppress_system_defined_TypeVars branch from 2021b43 to 8932dfd Compare May 9, 2020 05:38
@tk0miya tk0miya force-pushed the suppress_system_defined_TypeVars branch from 8932dfd to a48da56 Compare May 9, 2020 05:40
@tk0miya tk0miya merged commit f37fa14 into sphinx-doc:3.x May 9, 2020
@tk0miya tk0miya deleted the suppress_system_defined_TypeVars branch May 9, 2020 05:56
@tk0miya
Copy link
Member Author

tk0miya commented May 9, 2020

I need to merge this into 3.0.x branch...

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 29, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant