ashb commented on a change in pull request #19890:
URL: https://github.com/apache/airflow/pull/19890#discussion_r759250354
##########
File path: scripts/in_container/run_mypy.sh
##########
@@ -20,18 +20,5 @@
. "$( dirname "${BASH_SOURCE[0]}" )/_in_container_script_init.sh"
export PYTHONPATH=${AIRFLOW_SOURCES}
-mypy_args=()
-
-# Mypy doesn't cope very well with namespace packages when give filenames (it
gets confused about the lack of __init__.py in airflow.providers, and thinks
airflow.providers.docker is the same as a "docker" top level module).
-#
-# So we instead need to convert the file names in to module names to check
-for filename in "$@";
-do
- if [[ "${filename}" == docs/* ]]; then
- mypy_args+=("$filename")
- else
- mypy_args+=("-m" "$(filename_to_python_module "$filename")")
- fi
-done
-
-mypy --namespace-packages "${mypy_args[@]}"
+# Seems that new mypy copes better with namespace packages
Review comment:
```suggestion
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]