-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
build: log build sources with -v #9672
Conversation
With the changes I've been making to mypy's import handling, I think this would be a useful thing to add preemptively. Note that I would have found this very useful at points, and I think others would too, eg python#7672 and python#8584 The existing logging ignores source_modules and source_text and won't help with determining what mypy things the module name for a given file is, which is useful for namespace package issues as in the complaint in python#8584.
Hmm, I see that when I turn this on to mypy itself, it claims that some sources from typeshed/stdlib/2 and typeshed/thir_party/2 are found, e.g.
(A total of 265 files, out of 1436 reported.) Any idea what's up with that? |
Hm, I'm guessing this is the new, improved file search? This was from
It does the right thing when I run
IIRC the former used to work. Well, I guess I never liked typeshed being embedded inside mypy (nor the test subdir for that matter), but here we are. |
IOW I realize I have to declare in favor of this PR, since this actually showed the error of my ways... :-) |
:-) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But I still want a -v flag that just prints the list of sources, and not all the other stuff that’s logged by -v. That could become -vv.
Also, wouldn’t it be nice if each source file was logged just before it got checked, instead of all ahead of the checking? Then it would intersperse this activity log with the errors, as found.
Yeah that would be nice, and there's still the "show all files reached by following imports" part of your original request. It also occurred to me that |
Presuming you meant ‘-p mypy’, maybe it just stops descending when it finds a package named ‘mypy’? |
Yeah, I meant |
I know you posted this a while ago but definitely a big YES to this. - Currently trying to help fix this VSCode mypy extension and that feature would come in might handy for this bug microsoft/vscode-mypy#123 Any suggestions for a quick fix? If the output can include files checked, even if they have no error, it makes clearing errors on files a lot easier... |
With the changes I've been making to mypy's import handling, I think
this would be a useful thing to add preemptively.
Note that I would have found this very useful at points, and I think
others would too, eg #7672 and #8584
The existing logging ignores source_modules and source_text and doesn't
help with determining what mypy things the module name for a given file
is. This is useful for namespace package issues as in the complaint in #8584.