title: python dataclasses with optional attributes
body: <p>How do you make Optional attr's of a dataclass?</p>
  <pre><code>from dataclasses import dataclass
  
  @dataclass
  class CampingEquipment:
      knife: bool
      fork: bool
      missing_flask_size: # what to write here?
      
  kennys_stuff = {
      'knife': True,
      'fork': True
  }
  
  print(CampingEquipment(**kennys_stuff))
  </code></pre>
  <p>I tried <code>field(init=False)</code>, but it gave me:</p>
  <pre><code>TypeError: CampingEquipment.__init__() missing 1 required positional argument: 'missing_flask_size'
  </code></pre>
  <p>By Optional I mean <code>__dict__</code> may contain the key &quot;missing_flask_size&quot; or not.  If I set a default value then the key will be there and it shouldn't be in some cases.  I want to check its type if it is there.</p>
  <p>I tried moving the <code>field(init=False)</code> to the type location (after the colon) so I could make it more explicit as to the thing I wanted optional would be the key and not the value.</p>
  <p>So I want this test to pass:</p>
  <pre><code>with pytest.raises(AttributeError):
      ce = CampingEquipment(**kennys_stuff)
      print(ce.missing_flask_size)
  </code></pre>