Skip to content

[DO NOT MERGE] Python 3.8 deprecation workflow validation #3112

[DO NOT MERGE] Python 3.8 deprecation workflow validation

[DO NOT MERGE] Python 3.8 deprecation workflow validation #3112

GitHub Actions / Test Results failed Aug 27, 2024 in 0s

1 fail, 20 skipped, 5 pass in 2m 47s

26 tests    5 ✅  2m 47s ⏱️
 1 suites  20 💤
 1 files     1 ❌

Results for commit 310bec9.

Annotations

Check warning on line 0 in apache_beam.io.gcp.bigtableio_it_test.TestWriteToBigtableXlangIT

See this annotation in the file changed.

@github-actions github-actions / Test Results

test_delete_column_family_mutation (apache_beam.io.gcp.bigtableio_it_test.TestWriteToBigtableXlangIT) failed

sdks/python/pytest_transformService.xml [took 10s]
Raw output
RuntimeError: SDK failed to start. Final status is exited
self = <apache_beam.io.gcp.bigtableio_it_test.TestWriteToBigtableXlangIT testMethod=test_delete_column_family_mutation>

    def test_delete_column_family_mutation(self):
      # create two column families
      col_fam = self.table.column_family('col_fam-1')
      col_fam.create()
      col_fam = self.table.column_family('col_fam-2')
      col_fam.create()
      # write a row with values in both column families to the table beforehand.
      write_row: DirectRow = DirectRow('key-1', self.table)
      write_row.set_cell('col_fam-1', b'col', b'val')
      write_row.set_cell('col_fam-2', b'col', b'val')
      write_row.commit()
    
      # prepare a row that will delete a column family from the row
      delete_row: DirectRow = DirectRow('key-1')
      delete_row.delete_cells('col_fam-1', delete_row.ALL_COLUMNS)
    
>     self.run_pipeline([delete_row])

apache_beam/io/gcp/bigtableio_it_test.py:371: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
apache_beam/io/gcp/bigtableio_it_test.py:223: in run_pipeline
    _ = (
apache_beam/pipeline.py:620: in __exit__
    self.result = self.run()
apache_beam/pipeline.py:594: in run
    return self.runner.run_pipeline(self, self._options)
apache_beam/runners/direct/test_direct_runner.py:42: in run_pipeline
    self.result = super().run_pipeline(pipeline, options)
apache_beam/runners/direct/direct_runner.py:128: in run_pipeline
    return runner.run_pipeline(pipeline, options)
apache_beam/runners/portability/fn_api_runner/fn_runner.py:195: in run_pipeline
    self._latest_run_result = self.run_via_runner_api(
apache_beam/runners/portability/fn_api_runner/fn_runner.py:221: in run_via_runner_api
    return self.run_stages(stage_context, stages)
apache_beam/runners/portability/fn_api_runner/fn_runner.py:443: in run_stages
    runner_execution_context.setup()
apache_beam/runners/portability/fn_api_runner/execution.py:775: in setup
    self._enqueue_stage_initial_inputs(stage)
apache_beam/runners/portability/fn_api_runner/execution.py:804: in _enqueue_stage_initial_inputs
    bundle_manager.data_api_service_descriptor())
apache_beam/runners/portability/fn_api_runner/execution.py:1046: in data_api_service_descriptor
    return self.worker_handlers[0].data_api_service_descriptor()
apache_beam/runners/portability/fn_api_runner/execution.py:1038: in worker_handlers
    self.execution_context.worker_handler_manager.get_worker_handlers(
apache_beam/runners/portability/fn_api_runner/worker_handlers.py:930: in get_worker_handlers
    worker_handler.start_worker()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <apache_beam.runners.portability.fn_api_runner.worker_handlers.DockerSdkWorkerHandler object at 0x7c22311a13d0>

    def start_worker(self):
      # type: () -> None
      credential_options = []
      try:
        # This is the public facing API, skip if it is not available.
        # (If this succeeds but the imports below fail, better to actually raise
        # an error below rather than silently fail.)
        # pylint: disable=unused-import
        import google.auth
      except ImportError:
        pass
      else:
        from google.auth import environment_vars
        from google.auth import _cloud_sdk
        gcloud_cred_file = os.environ.get(
            environment_vars.CREDENTIALS,
            _cloud_sdk.get_application_default_credentials_path())
        if os.path.exists(gcloud_cred_file):
          docker_cred_file = '/docker_cred_file.json'
          credential_options.extend([
              '--mount',
              f'type=bind,source={gcloud_cred_file},target={docker_cred_file}',
              '--env',
              f'{environment_vars.CREDENTIALS}={docker_cred_file}'
          ])
      with SUBPROCESS_LOCK:
        try:
          _LOGGER.info('Attempting to pull image %s', self._container_image)
          subprocess.check_call(['docker', 'pull', self._container_image])
        except Exception:
          _LOGGER.info(
              'Unable to pull image %s, defaulting to local image if it exists' %
              self._container_image)
        self._container_id = subprocess.check_output([
            'docker',
            'run',
            '-d',
            '--network=host',
        ] + credential_options + [
            self._container_image,
            '--id=%s' % self.worker_id,
            '--logging_endpoint=%s' % self.logging_api_service_descriptor().url,
            '--control_endpoint=%s' % self.control_address,
            '--artifact_endpoint=%s' % self.control_address,
            '--provision_endpoint=%s' % self.control_address,
        ]).strip()
        assert self._container_id is not None
        while True:
          status = subprocess.check_output([
              'docker', 'inspect', '-f', '{{.State.Status}}', self._container_id
          ]).strip()
          _LOGGER.info(
              'Waiting for docker to start up. Current status is %s' %
              status.decode('utf-8'))
          if status == b'running':
            _LOGGER.info(
                'Docker container is running. container_id = %s, '
                'worker_id = %s',
                self._container_id,
                self.worker_id)
            break
          elif status in (b'dead', b'exited'):
            subprocess.call(['docker', 'container', 'logs', self._container_id])
>           raise RuntimeError(
                'SDK failed to start. Final status is %s' %
                status.decode('utf-8'))
E           RuntimeError: SDK failed to start. Final status is exited

apache_beam/runners/portability/fn_api_runner/worker_handlers.py:807: RuntimeError