Open schlamar opened 4 years ago
No error for code snippet below.
Error Inheriting 'Base', which is not a class.
Inheriting 'Base', which is not a class
from sqlalchemy import Column, Integer, String from sqlalchemy.ext.declarative import declarative_base Base = declarative_base() class User(Base): __tablename__ = 'users' id = Column(Integer, primary_key=True) name = Column(String) fullname = Column(String) nickname = Column(String) def __repr__(self): return "<User(name='%s', fullname='%s', nickname='%s')>" % ( self.name, self.fullname, self.nickname)
For now, you may disable inherit-non-class by following the instructions in https://github.com/microsoft/python-language-server#linting-options-diagnostics, or by using # noqa on the class line.
inherit-non-class
# noqa
Environment data
Expected behaviour
No error for code snippet below.
Actual behaviour
Error
Inheriting 'Base', which is not a class
.Code Snippet