title: Delegating attributes to those of a OneToOneField in Django
body: <p>I have a model <code>UserGuide</code> which extends Django's <code>User</code> model through a one-to-one relationship. I would like to make it such that for an instance <code>lucy_guide</code>, a call to an attribute <code>lucy_guide.first_name</code> will return <code>luyy_guide.user.first_name</code> (and similar for <code>last_name</code>). Here is my first pass at implementing this:</p>
  
  <pre><code>class LucyGuide(models.Model):
      user = models.OneToOneField(User, on_delete=models.CASCADE)
  
      def __getattr__(self, attr):
          if attr in ['first_name', 'last_name'] and self.user:
              return getattr(self.user, attr)
          return super().__getattr__(attr)
  </code></pre>
  
  <p>Does this look OK? I know Django can behave differently from 'regular Python' due to its use of metaclasses.</p>