title: When using Beam IO ReadFromPubSub module, can you pull messages with attributes in Python? It's unclear if its supported
body: <p>Trying to pull messages with attributes stored in PubSub into a Beam pipeline. I'm wondering if support has been added for Python and that's why I'm unable to read them. I see that it exists in Java.</p>
  
  <pre><code>pipeline_options = PipelineOptions()
  pipeline_options.view_as(StandardOptions).streaming = True
  
  pipeline = beam.Pipeline(options=pipeline_options)
  messages = (pipeline | beam.io.ReadFromPubSub(subscription=subscription_name).with_output_types(bytes))
  
  def printattr(element):
      print(element.attributes)
  
  
  lines = messages | 'printattr' &gt;&gt; beam.Map(printattr)
  
  result = pipeline.run()
  result.wait_until_finish()
  </code></pre>
  
  <p>Expected to be able to list the attributes- data: </p>
  
  <pre><code>b'Message number 1109'
  -     attributes: {
  -       "_comments": "nan",
  -       "_direction": "SE",
  -       "_fromst": "Harlem",
  -       "_last_updt": "2019-03-20 21:11:02.0",
  -       "_length": "0.56",
  -       "_lif_lat": "41.9809967484",
  -       "_lit_lat": "41.9787314076",
  -       "_lit_lon": "-87.7964600566",
  -       "_strheading": "W",
  -       "_tost": "Oak Park",
  </code></pre>
  
  <p>, but I can only seem to access information stored in the data field- not the attributes.</p>