title: ArgumentError: relationship expects a class or mapper argument
body: <p>I am getting this strange error, and I'm saying strange because I made a change to an unrelated table.</p>
  
  <p>I am trying to query my <code>tDevice</code> table which looks like this:</p>
  
  <pre><code>class TDevice(Base):
      __tablename__ = 'tDevice'
  
      ixDevice = Column(Integer, primary_key=True)
      ixDeviceType = Column(Integer, ForeignKey('tDeviceType.ixDeviceType'), nullable=False)
      ixSubStation = Column(Integer, ForeignKey('tSubStation.ixSubStation'), nullable=False)
      ixModel = Column(Integer, ForeignKey('tModel.ixModel'), nullable=True)
      ixParentDevice = Column(Integer, ForeignKey('tDevice.ixDevice'), nullable=True)
      sDeviceName = Column(Unicode(255), nullable=False)#added
  
      children = relationship('TDevice',
                          backref=backref('parent', remote_side=[ixDevice]))
  
      device_type = relationship('TDeviceType',
                             backref=backref('devices'))
  
      model = relationship('TModel',
                       backref=backref('devices'))
  
      sub_station = relationship('TSubStation',
                             backref=backref('devices'))
  </code></pre>
  
  <p>and this is how  I query it:</p>
  
  <pre><code>Device = DBSession.query(TDevice).filter(TDevice.ixDevice == device_id).one()
  </code></pre>
  
  <p>as soon as this line is executed, I get the error:</p>
  
  <pre><code>ArgumentError: relationship 'report_type' expects a class or a mapper argument (received: &lt;class 'sqlalchemy.sql.schema.Table'&gt;)
  </code></pre>
  
  <p>The only changes I've made is add a report_type relationship in my <code>tReportTable</code>
  which now looks like this:</p>
  
  <pre><code>class TReport(Base):
  __tablename__ = 'tReport'
  
  ixReport = Column(Integer, primary_key=True)
  ixDevice = Column(Integer, ForeignKey('tDevice.ixDevice'), nullable=False)
  ixJob = Column(Integer, ForeignKey('tJob.ixJob'), nullable=False)
  ixReportType = Column(Integer, ForeignKey('tReportType.ixReportType'), nullable=False) # added
  
  report_type = relationship('tReportType',
                             uselist=False,
                             backref=backref('report'))
  
  device = relationship('TDevice',
                        uselist=False,
                        backref=backref('report'))
  
  job = relationship('TJob',
                     uselist=False,
                     backref=backref('report'))
  </code></pre>
  
  <p>I'm still new to SqlAlchemy so I can't seem to see how adding that relationship should be causing this error if I am iterating another table</p>