title: Is there a way to get type of related field from a model queryset in Django?
body: <p>Can I get type of related field from a model queryset?</p>
  
  <p>Let consider example model:</p>
  
  <pre><code>class Semester(models.Model):
      active = models.BooleanField(default=False, verbose_name="Active")
  
  class Subject(models.Model):
      name = models.CharField(max_length=100, verbose_name="Name")
      semester = models.ForeignKey(Semester, verbose_name="Semester")
  </code></pre>
  
  <p>if I have some field name in variable and queryset I can do this:</p>
  
  <pre><code>querySet = Subject.objects.all()
  
  some_field_name = 'name'
  field_type = querySet.model._meta.get_field(some_field_name).get_internal_type()
  </code></pre>
  
  <p>Is there any way to get related field type, for example:</p>
  
  <pre><code>querySet = Subject.objects.all()
  
  some_field_name = 'semester__active'
  field_type = ?
  </code></pre>