Skip to content

Instantly share code, notes, and snippets.

@suztomo
Created November 22, 2019 02:28
Show Gist options
  • Save suztomo/ebfc110652b8ffaf7fede64276d7a053 to your computer and use it in GitHub Desktop.
Save suztomo/ebfc110652b8ffaf7fede64276d7a053 to your computer and use it in GitHub Desktop.
:sdks:python:test-suites:tox:py36:testPy36Gcp failure
Ran 2955 tests in 648.661s
OK (SKIP=315)
py35-gcp run-test-post: commands[0] | /usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py35/build/srcs/sdks/python/scripts/run_tox_cleanup.sh
___________________________________ summary ____________________________________
py35-gcp: commands succeeded
congratulations :)
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':sdks:python:test-suites:tox:py36:testPy36Gcp'.
> Process 'command 'sh'' finished with non-zero exit value 1
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/5.2.1/userguide/command_line_interface.html#sec:command_line_warnings
BUILD FAILED in 11m 47s
22 actionable tasks: 21 executed, 1 up-to-date
@suztomo
Copy link
Author

suztomo commented Nov 22, 2019

Using /usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/.eggs/ptyprocess-0.6.0-py3.6.egg
Failure: ModuleNotFoundError (No module named '_bz2') ... ERROR

======================================================================
ERROR: Failure: ModuleNotFoundError (No module named '_bz2')
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/target/.tox-py36-gcp/py36-gcp/lib/python3.6/site-packages/nose/failure.py", line 39, in runTest
    raise self.exc_val.with_traceback(self.tb)
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/target/.tox-py36-gcp/py36-gcp/lib/python3.6/site-packages/nose/loader.py", line 418, in loadTestsFromName
    addr.filename, addr.module)
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/target/.tox-py36-gcp/py36-gcp/lib/python3.6/site-packages/nose/importer.py", line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/target/.tox-py36-gcp/py36-gcp/lib/python3.6/site-packages/nose/importer.py", line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/target/.tox-py36-gcp/py36-gcp/lib/python3.6/imp.py", line 245, in load_module
    return load_package(name, filename)
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/target/.tox-py36-gcp/py36-gcp/lib/python3.6/imp.py", line 217, in load_package
    return _load(spec)
  File "<frozen importlib._bootstrap>", line 684, in _load
  File "<frozen importlib._bootstrap>", line 665, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 678, in exec_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/__init__.py", line 98, in <module>
    from apache_beam import io
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/io/__init__.py", line 22, in <module>
    from apache_beam.io.avroio import *
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/io/avroio.py", line 61, in <module>
    from apache_beam.io import filebasedsink
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/io/filebasedsink.py", line 34, in <module>
    from apache_beam.io import iobase
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/io/iobase.py", line 51, in <module>
    from apache_beam.transforms import core
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/transforms/__init__.py", line 25, in <module>
    from apache_beam.transforms.external import *
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/transforms/external.py", line 36, in <module>
    from apache_beam.runners import pipeline_context
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/runners/__init__.py", line 31, in <module>
    from apache_beam.runners.dataflow.dataflow_runner import DataflowRunner
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/runners/dataflow/__init__.py", line 26, in <module>
    from apache_beam.runners.dataflow.dataflow_runner import DataflowRunner
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/runners/dataflow/dataflow_runner.py", line 83, in <module>
    class DataflowRunner(PipelineRunner):
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/runners/dataflow/dataflow_runner.py", line 102, in DataflowRunner
    from apache_beam.runners.dataflow.ptransform_overrides import CreatePTransformOverride
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/runners/dataflow/ptransform_overrides.py", line 23, in <module>
    from apache_beam.pipeline import PTransformOverride
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/pipeline.py", line 62, in <module>
    from apache_beam.io.filesystems import FileSystems
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/io/filesystems.py", line 27, in <module>
    from apache_beam.io.filesystem import BeamIOError
  File "/usr/local/google/home/suztomo/beam4/sdks/python/test-suites/tox/py36/build/srcs/sdks/python/apache_beam/io/filesystem.py", line 28, in <module>
    import bz2
  File "/usr/local/google/home/suztomo/local/lib/python3.6/bz2.py", line 23, in <module>
    from _bz2 import BZ2Compressor, BZ2Decompressor
ModuleNotFoundError: No module named '_bz2'

It seems my Python3.6 installation was missing bz2
https://stackoverflow.com/questions/50335503/no-module-named-bz2-in-python3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment