title: Asynchronous property setter
body: <p>Let us suppose we have a class with a property that can only be set asynchronously. Is there a way to make this work without explicitly calling a setter?</p>
  <p>MNWE:</p>
  <pre><code>import asyncio
  
  loop = asyncio.get_event_loop()
  
  class AsyncTest:
      def __init__(self, attrib):
          self._attrib = attrib
  
      @property
      def attrib(self):
          return self._attrib
  
      @attrib.setter
      async def set_attrib(self, attrib):
          await asyncio.sleep(1.0)
          self._attrib = attrib
  
  
  async def main():
      t = AsyncTest(1)
      print(t.attrib)
      await t.attrib = 3
      print(t.attrib)
  
  asyncio.ensure_future(main())
  loop.run_forever()
  </code></pre>
  <p>This fails with</p>
  <pre><code>  File &quot;asyncprop.py&quot;, line 22
      await t.attrib = 3
         ^
  SyntaxError: can't assign to await expression
  </code></pre>
  <p>which is not surprising, given that the grammar for <code>await</code> is</p>
  <pre><code>await ::=  [&quot;await&quot;] primary
  </code></pre>
  <p>So it seems we are bound to forget this nice <code>@property</code> and resign ourselves to using getters and setters for asynchronous operations. Did I miss something?</p>