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
My editor is configured to use pyright lsp and mypy for type checking. I'm working in a virtualenv with mypy, pyright, and micropython-stubs installed. I'm currently having the following issues:
pyright
$ pyright code.py
/home/ben/Projects/personal/circuitpy/code.py
/home/ben/Projects/personal/circuitpy/code.py:3:8 - warning: Import "board" could not be resolved from source (reportMissingModuleSource)
/home/ben/Projects/personal/circuitpy/code.py:4:8 - warning: Import "digitalio" could not be resolved from source (reportMissingModuleSource)
/home/ben/Projects/personal/circuitpy/code.py:8:36 - error: "LED" is not a known attribute of module "board" (reportAttributeAccessIssue)
1 error, 2 warnings, 0 informations
It's unclear what other packages my editor needs installed for mypy linting and code completion.
mypy
$ mypy code.py
code.py:8: error: Module has no attribute "LED" [attr-defined]
Found 1 error in 1 file (checked 1 source file)
With mypy, I'm unable to resolve any attributes for the board and digitalio module.
Additional information
No response
The text was updated successfully, but these errors were encountered:
CircuitPython version
Code/REPL
Behavior
n/a
Description
My editor is configured to use pyright lsp and mypy for type checking. I'm working in a virtualenv with
mypy
,pyright
, andmicropython-stubs
installed. I'm currently having the following issues:pyright
It's unclear what other packages my editor needs installed for mypy linting and code completion.
mypy
With mypy, I'm unable to resolve any attributes for the
board
anddigitalio
module.Additional information
No response
The text was updated successfully, but these errors were encountered: