title: Python: Adding Fields to Objects Dynamically
body: <p>I am wondering whether it is possible to add fields to objects dynamically. For example, I want to be able to add something like:</p>
  
  <pre><code>user = object()
  user.first_name = 'John'
  user.last_name = 'Smith'
  </code></pre>
  
  <p>When I execute that in Python command line interpretor I get:</p>
  
  <pre><code>AttributeError: 'object' object has no attribute 'first_name'
  </code></pre>
  
  <p>Any idea?</p>