PTVS icon indicating copy to clipboard operation
PTVS copied to clipboard

The type information displayed wrong for sys.exc_info with the latest typeshed

Open linette-zyy opened this issue 3 years ago • 5 comments

Environment image

Steps to Reproduce

  1. Ensure the option is unchecked by default a. Check there is type information in below example image image image
  2. Custom Typeshed path a. git clone https://github.com/python/typeshed, enter the local path on disk where you cloned the repository image b. open typeshed/stdlib/sys.pyi
		def exc_info() -> Tuple[Optional[Type[BaseException]],
		                        Optional[BaseException],
		                        Optional[TracebackType]]: ...
	With this instead:
	 
		def exc_info() -> Tuple[Optional[Type[BaseException]],
		                        Optional[BaseException],
		                        Optional[_version_info]]: ...
c. Close and reopen the project

Expected behavior It should now report e3 as being a version info instance image image

Actual result All type information displayed "Any" image image image

linette-zyy avatar Dec 30 '21 07:12 linette-zyy

@bschnurr I don't know enough about this to comment. Should we reach out to Eric?

AdamYoblick avatar Jan 05 '22 22:01 AdamYoblick

most likely a ptvs issue. could be we aren't passing/setting the typeshed path correctly. I can take a look

bschnurr avatar Jan 06 '22 00:01 bschnurr

maybe we expect relative path

bschnurr avatar Jan 06 '22 00:01 bschnurr

hmm.. couldn't repo Version 17.1.0 Preview 3.0 [32105.426.main] image

bschnurr avatar Jan 06 '22 22:01 bschnurr

I verify this issue on the latest build. It still reproduced. image

image

linette-zyy avatar Jan 10 '22 08:01 linette-zyy

@linette-zyy I'm closing this out since it's old. Does this still repro on the latest build? If it does, please reopen this so we can investigate.

AdamYoblick avatar Jan 26 '23 22:01 AdamYoblick