Skip to content

Commit

Permalink
mypy quality of life fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Jacob Beck committed Aug 6, 2019
1 parent 1a618e7 commit d08d291
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ var/
*.egg-info/
.installed.cfg
*.egg
*.mypy_cache/
logs/

# PyInstaller
Expand Down
1 change: 1 addition & 0 deletions core/dbt/py.typed
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# dummy file, our types are defined inline
1 change: 1 addition & 0 deletions core/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ def read(fname):
'include/global_project/macros/*.sql',
'include/global_project/macros/**/*.sql',
'include/global_project/macros/**/**/*.sql',
'py.typed',
]
},
test_suite='test',
Expand Down
19 changes: 19 additions & 0 deletions third-party-stubs/agate/__init__.pyi
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
from typing import Any, Optional

class Table:
def __init__(self, rows: Any, column_names: Optional[Any] = ..., column_types: Optional[Any] = ..., row_names: Optional[Any] = ..., _is_fork: bool = ...) -> None: ...
def __len__(self): ...
def __iter__(self): ...
def __getitem__(self, key: Any): ...
@property
def column_types(self): ...
@property
def column_names(self): ...
@property
def row_names(self): ...
@property
def columns(self): ...
@property
def rows(self): ...
def print_csv(self, **kwargs: Any) -> None: ...
def print_json(self, **kwargs: Any) -> None: ...

0 comments on commit d08d291

Please sign in to comment.