Skip to content

Commit

Permalink
skipping mypy plugins (sqlalchemy and pydantic) for now since they ar…
Browse files Browse the repository at this point in the history
…e blocking airflow work. will sync up with Saul to see if this is acceptable or if we have a better solution.
  • Loading branch information
lionsardesai committed Oct 20, 2021
1 parent 0caa77f commit c0b2745
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
18 changes: 9 additions & 9 deletions lineapy/db/relational/schema/relational.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ def process_result_value(self, value, dialect):
return value


class SessionContextORM(Base):
class SessionContextORM(Base): # type: ignore
__tablename__ = "session_context"
id = Column(String, primary_key=True)
environment_type = Column(Enum(SessionType))
Expand All @@ -108,7 +108,7 @@ class SessionContextORM(Base):
execution_id = Column(String, ForeignKey("execution.id"))


class LibraryORM(Base):
class LibraryORM(Base): # type: ignore
__tablename__ = "library"
__table_args__ = (
UniqueConstraint(
Expand All @@ -125,7 +125,7 @@ class LibraryORM(Base):
path = Column(String)


class ArtifactORM(Base):
class ArtifactORM(Base): # type: ignore
"""
An artifact is a named pointer to a node.
"""
Expand All @@ -140,7 +140,7 @@ class ArtifactORM(Base):
)


class ExecutionORM(Base):
class ExecutionORM(Base): # type: ignore
"""
An execution represents one Python interpreter invocation of some number of nodes
"""
Expand All @@ -150,7 +150,7 @@ class ExecutionORM(Base):
timestamp = Column(DateTime, nullable=True, default=datetime.utcnow)


class NodeValueORM(Base):
class NodeValueORM(Base): # type: ignore
"""
A node value represents the value of a node during some execution.
Expand All @@ -170,7 +170,7 @@ class NodeValueORM(Base):
end_time = Column(DateTime, nullable=True)


class BaseNodeORM(Base):
class BaseNodeORM(Base): # type: ignore
"""
node.source_code has a path value if node.session.environment_type == "script"
otherwise the environment type is "jupyter" and it has a jupyter execution
Expand Down Expand Up @@ -214,7 +214,7 @@ class BaseNodeORM(Base):
}


class SourceCodeORM(Base):
class SourceCodeORM(Base): # type: ignore
__tablename__ = "source_code"

id = Column(String, primary_key=True)
Expand Down Expand Up @@ -261,7 +261,7 @@ class ImportNodeORM(BaseNodeORM):
# https://docs.sqlalchemy.org/en/14/orm/basic_relationships.html#association-object


class PositionalArgORM(Base):
class PositionalArgORM(Base): # type: ignore
__tablename__ = "positional_arg"
call_node_id: str = Column(
ForeignKey("call_node.id"), primary_key=True, nullable=False
Expand All @@ -273,7 +273,7 @@ class PositionalArgORM(Base):
argument = relationship(BaseNodeORM, uselist=False)


class KeywordArgORM(Base):
class KeywordArgORM(Base): # type: ignore
__tablename__ = "keyword_arg"
call_node_id: str = Column(
ForeignKey("call_node.id"), primary_key=True, nullable=False
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ relative_files = true

# https://docs.sqlalchemy.org/en/14/orm/extensions/mypy.html
# https://pydantic-docs.helpmanual.io/mypy_plugin/#enabling-the-plugin
plugins = ["sqlalchemy.ext.mypy.plugin", "pydantic.mypy"]
# plugins = ["sqlalchemy.ext.mypy.plugin", "pydantic.mypy"]


# Enable function body type checking, even if function types are not annotated
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def version(path):
"sklearn",
"flake8",
"syrupy==1.4.5",
"mypy==0.770",
"mypy",
"isort",
"pytest",
"matplotlib",
Expand Down

0 comments on commit c0b2745

Please sign in to comment.