msherry / flycheck-pycheckers

Multiple syntax checker for Python in Emacs, using Flycheck
GNU General Public License v3.0
63 stars 23 forks source link

Mypy reveal_type() gets suppressed #38

Closed efroemling closed 5 years ago

efroemling commented 5 years ago

I just came back to a project after a while and noticed that I'm no longer able to do use Mypy's reveal_type() with pycheckers. Mypy is emitting an error level of 'note:' in this case which seems to get filtered out by fixup_data() in pycheckers' mypy checker. Perhaps mypy used to emit errors and not notes for reveal_type()?.. I'm able to work around it for now by hacking fixup_data() to map that particular case back to an error, but perhaps you'd want to fix this in a cleaner way? (I'd be happy to throw my hack up as a PR if not; just let me know) -Eric

msherry commented 5 years ago

It looks like the level for reveal_type messages changed in https://github.com/python/mypy/pull/6919. It sounds like we should probably display messages at the note level, since there are at least two debugging functions (reveal_type and reveal_locals) that use it now.

I'll take a look and see if I can get a fix up shortly -- thanks for bringing it to my attention!