Uploaded image for project: 'Beam'
  1. Beam
  2. BEAM-9671

[on-hold] Cross language pipelines not working due to metrics issue

Details

    • Bug
    • Status: Resolved
    • P2
    • Resolution: Not A Problem
    • None
    • Not applicable
    • sdk-py-core, testing
    • None

    Description

      I'm trying to use cross-language framework to invoke java IOs in python, but it was failing on some imports related to metrics.

      I tracked it down and it seems that [PR-11184|https://github.com/apache/beam/pull/11184] for ****BEAM-4374 has some bug with imports.

       

      I managed to find appropriate test:

      monitoring_infos_test.py

      which is failing on the vary same issue:

      $ python sdks/python/apache_beam/metrics/monitoring_infos_test.py 
      Traceback (most recent call last):
        File "/dariusz/metrics/monitoring_infos_test.py", line 23, in <module>
          from apache_beam.metrics import monitoring_infos
        File "/dariusz/beam/sdks/python/apache_beam/__init__.py", line 96, in <module>
          from apache_beam import io
        File "/dariusz/beam/sdks/python/apache_beam/io/__init__.py", line 23, in <module>
          from apache_beam.io.avroio import *
        File "/dariusz/beam/sdks/python/apache_beam/io/avroio.py", line 64, in <module>
          from apache_beam.io import filebasedsink
        File "/dariusz/beam/sdks/python/apache_beam/io/filebasedsink.py", line 36, in <module>
          from apache_beam.io import iobase
        File "/dariusz/beam/sdks/python/apache_beam/io/iobase.py", line 57, in <module>
          from apache_beam.transforms import core
        File "/dariusz/beam/sdks/python/apache_beam/transforms/__init__.py", line 29, in <module>
          from apache_beam.transforms.util import *
        File "/dariusz/beam/sdks/python/apache_beam/transforms/util.py", line 50, in <module>
          from apache_beam.metrics import Metrics
        File "/dariusz/beam/sdks/python/apache_beam/metrics/__init__.py", line 19, in <module>
          from apache_beam.metrics.metric import Metrics
        File "/dariusz/beam/sdks/python/apache_beam/metrics/metric.py", line 35, in <module>
          from apache_beam.metrics.execution import MetricUpdater
        File "/dariusz/beam/sdks/python/apache_beam/metrics/execution.py", line 39, in <module>
          from apache_beam.metrics import monitoring_infos
        File "/dariusz/beam/sdks/python/apache_beam/metrics/monitoring_infos.py", line 51, in <module>
          USER_COUNTER_URN = common_urns.monitoring_info_specs.USER_SUM_INT64.spec.urn
      AttributeError: type object 'Enum' has no attribute 'USER_SUM_INT64'
      
      

      can you please take a look?

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              dariusz.aniszewski Dariusz Aniszewski
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: