[SPARK-32714][FOLLOW-UP][PYTHON] Address pyspark.install typing errors
### What changes were proposed in this pull request?
This PR adds two `type: ignores`, one in `pyspark.install` and one in related tests.
### Why are the changes needed?
To satisfy MyPy type checks. It seems like we originally missed some changes that happened around merge of
31a16fbb40
```
python/pyspark/install.py:30: error: Need type annotation for 'UNSUPPORTED_COMBINATIONS' (hint: "UNSUPPORTED_COMBINATIONS: List[<type>] = ...") [var-annotated]
python/pyspark/tests/test_install_spark.py:105: error: Cannot find implementation or library stub for module named 'xmlrunner' [import]
python/pyspark/tests/test_install_spark.py:105: note: See https://mypy.readthedocs.io/en/latest/running_mypy.html#missing-imports
```
### Does this PR introduce _any_ user-facing change?
No.
### How was this patch tested?
- Existing tests.
- MyPy tests
```
mypy --show-error-code --no-incremental --config python/mypy.ini python/pyspark
```
Closes #29878 from zero323/SPARK-32714-FOLLOW-UP.
Authored-by: zero323 <mszymkiewicz@gmail.com>
Signed-off-by: HyukjinKwon <gurwls223@apache.org>
This commit is contained in:
parent
0c38765b29
commit
c65b64552f
|
@ -27,7 +27,7 @@ DEFAULT_HADOOP = "hadoop3.2"
|
|||
DEFAULT_HIVE = "hive2.3"
|
||||
SUPPORTED_HADOOP_VERSIONS = ["hadoop2.7", "hadoop3.2", "without-hadoop"]
|
||||
SUPPORTED_HIVE_VERSIONS = ["hive2.3"]
|
||||
UNSUPPORTED_COMBINATIONS = [
|
||||
UNSUPPORTED_COMBINATIONS = [ # type: ignore
|
||||
]
|
||||
|
||||
|
||||
|
|
|
@ -102,7 +102,7 @@ if __name__ == "__main__":
|
|||
from pyspark.tests.test_install_spark import * # noqa: F401
|
||||
|
||||
try:
|
||||
import xmlrunner
|
||||
import xmlrunner # type: ignore[import]
|
||||
testRunner = xmlrunner.XMLTestRunner(output='target/test-reports', verbosity=2)
|
||||
except ImportError:
|
||||
testRunner = None
|
||||
|
|
Loading…
Reference in a new issue