You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 14, 2022. It is now read-only.
Repository navigation
This repository was archived by the owner on Apr 14, 2022. It is now read-only.
GenericPath test failing after typeshed upgrade #1654
After upgrading typeshed to a newer version, the GenericPath test fails. It looks like the __truediv__ function on Path/PurePath/etc do not have their return values set correctly. The code added in #1463 doesn't even execute.
Split from #1371, since this is taking a good chunk of time investigating.
When building the overload, it tries to look up _P, but with the new typeshed, _P doesn't exist in the global scope. On master, it is in the global scope.
And it works. I'm not sure that this should be legal, as PEP 484 says that forward references need to be wrapped in quotes, and we assume this behavior...
Filed python/typeshed#3334. Worst case I can pin to something before that change, but typeshed hasn't yet fully updated to 3.8's new stuff yet as far as I can tell.
Activity
jakebailey commentedon Oct 9, 2019
When building the overload, it tries to look up
_P, but with the new typeshed,_Pdoesn't exist in the global scope. On master, it is in the global scope.jakebailey commentedon Oct 9, 2019
Change:
To:
And it works. I'm not sure that this should be legal, as PEP 484 says that forward references need to be wrapped in quotes, and we assume this behavior...
jakebailey commentedon Oct 9, 2019
Filed python/typeshed#3334. Worst case I can pin to something before that change, but typeshed hasn't yet fully updated to 3.8's new stuff yet as far as I can tell.
jakebailey commentedon Oct 9, 2019
Handling the assignment of
_P, it goes and tries to evaluate the TypeVar call, which then makes its way down to handling the evaluation ofPurePathjakebailey commentedon Oct 9, 2019
Can be fixed by skipping the extra eval in GetValueFromName if the module being analyzed is a stub. Better fixed by using lazy references (future).