I am currently developing Airflow DAGs using Python. I am using:
When I use the bit-shift operator to compose the relationships between different Operators, I have this warning in VSCode:
Expression value is unused
I would like to keep type checking enabled in VSCode, but I don't want to see this warning for valid use cases like composing Airflow DAGs.
Is there a way to configure Pylance to suppress this specific warning for the bit-shift operator?
I tried to set a mypy.ini
in my settings with the code below, it doesnt do anything.
[mypy]
warn_unused_ignores = False
The VSCode mypy extension settings look like:
Can anyone help me figure out how to resolve this issue without disabling type checking entirely?
Try this in vs code settings.json
:
"python.analysis.diagnosticSeverityOverrides": {
"reportUnusedExpression": "none"
}