Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

MyPy linting output not being shown in Problems tab #2380

Copy link
Copy link
@AllanDaemon

Description

@AllanDaemon
Issue body actions

Environment data

  • VS Code version:
    • Version: 1.25.1
    • Commit: 1dfc5e557209371715f655691b1235b6b26a06be
    • Date: 2018-07-11T15:40:20.190Z
    • Electron: 1.7.12
    • Chrome: 58.0.3029.110
    • Node.js: 7.9.0
    • V8: 5.8.283.38
    • Architecture: x64
  • Extension version:
    • Python (ms-python.python) 2018.7.1
    • MagicPython 1.0.12
  • OS and version: Fedora 28 (Linux 4.16.14-300.fc28.x86_64 1228 multi root master #1 SMP)
  • Python version: python3.7 (from fedora package python37)
  • Type of virtual environment used: N/A
  • Relevant/affected Python packages and their versions: mypy 0.620

Actual behavior

mypy and pylint are executed and show errors on the output/python tab, but just the pylint errors are shown on the problems tab.

Expected behavior

problems tab shows both pylint and mypy errors

Steps to reproduce:

  1. Install Python 3.7 (dnf install python37 on Fedora)
  2. Install pip on python3.7
  3. sudo python3.7 -m pip install --pre -U mypy pylint

Logs

Code for test
UPDATE: save file as name.pyi

#!/usr/bin/env python3.7
from __future__ import annotations

a:int = "a"
not_declared_var
##########Linting Output - mypy##########
mypy /home/rea/code/rfs/provider.pyi
provider.pyi:10: error: Incompatible types in assignment (expression has type "str", variable has type "int")
provider.pyi:11: error: Name 'not_declared_var' is not defined
##########Linting Output - pylint##########
************* Module provider
11,0,error,E0602:Undefined variable 'not_declared_var'

------------------------------------------------------------------
Your code has been rated at 0.00/10 (previous run: 0.00/10, +0.00)

Show on problem tab:

E0602:Undefined variable 'not_declared_var'

Output from Console under the Developer Tools panel

workbench.main.js:sourcemap:4103 Overwriting grammar scope name to file mapping for scope source.python.
Old grammar file: file:///usr/share/code/resources/app/extensions/python/syntaxes/MagicPython.tmLanguage.json.
New grammar file: file:///home/rea/.vscode/extensions/magicstack.magicpython-1.0.12/grammars/MagicPython.tmLanguage

My config (relevant parts):
User

{
    "python.globalModuleInstallation": true,
    "python.pythonPath": "/usr/bin/python3",
    "files.exclude": {
        "**/__pycache__": true,
        "**/db.sqlite3": true,
    },
    "terminal.integrated.shell.linux": "/bin/shell",
    "files.autoSave": "off",
    "python.linting.pylintPath": "/usr/local/bin/pylint",
    "python.analysis.typeshedPaths": [ "/usr/share/typeshed/"],
    "python.autoComplete.typeshedPaths": [
        "/usr/share/typeshed/"
    ],
}

Workspace

{
	"folders": [
		{
			"path": ".."
		}
	],
	"settings": {  "files.exclude": {
		"**/.git": true,
		"**/.svn": true,
		"**/.hg": true,
		"**/CVS": true,
		"**/.DS_Store": true,
		".gitignore": true,
	},
	"python.pythonPath": "/usr/bin/python3.7",
	"python.linting.pylintPath": "/usr/local/bin/pylint3.7",
	"python.linting.mypyEnabled": true,
	"python.linting.mypyPath": "/usr/bin/mypy3.7",
	"python.linting.mypyArgs": [],
}
}

content of /usr/bin/mypy3.7:

#!/bin/sh
exec python3.7 -m mypy --python-version 3.7 $@

I've looked in #343 and #1440 also, but no luck.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-lintingbugIssue identified by VS Code Team member as probable bugIssue identified by VS Code Team member as probable bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.