Skip to content

Commit

Permalink
Fix typing errors in core/dbt/contracts/sql.py
Browse files Browse the repository at this point in the history
  • Loading branch information
QMalcolm committed Aug 27, 2024
1 parent f25a474 commit b2a8ea6
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
6 changes: 6 additions & 0 deletions .changes/unreleased/Under the Hood-20240827-113123.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
kind: Under the Hood
body: Fix typing issues in core/dbt/contracts/sql.py
time: 2024-08-27T11:31:23.749912-05:00
custom:
Author: QMalcolm
Issue: "10614"
5 changes: 3 additions & 2 deletions core/dbt/contracts/sql.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ class RemoteCompileResult(RemoteCompileResultMixin):
generated_at: datetime = field(default_factory=datetime.utcnow)

@property
def error(self):
def error(self) -> None:

Check warning on line 32 in core/dbt/contracts/sql.py

View check run for this annotation

Codecov / codecov/patch

core/dbt/contracts/sql.py#L32

Added line #L32 was not covered by tests
# TODO: Can we delete this? It's never set anywhere else and never accessed
return None


Expand All @@ -40,7 +41,7 @@ class RemoteExecutionResult(ExecutionResult):
args: Dict[str, Any] = field(default_factory=dict)
generated_at: datetime = field(default_factory=datetime.utcnow)

def write(self, path: str):
def write(self, path: str) -> None:

Check warning on line 44 in core/dbt/contracts/sql.py

View check run for this annotation

Codecov / codecov/patch

core/dbt/contracts/sql.py#L44

Added line #L44 was not covered by tests
writable = RunResultsArtifact.from_execution_results(
generated_at=self.generated_at,
results=self.results,
Expand Down

0 comments on commit b2a8ea6

Please sign in to comment.