Skip to content

Commit

Permalink
fix indentation, add missing docstring to appease our sphinx lords
Browse files Browse the repository at this point in the history
  • Loading branch information
cmpadden committed Aug 21, 2024
1 parent d3d8491 commit 2410489
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 4 deletions.
9 changes: 9 additions & 0 deletions python_modules/dagster-pipes/dagster_pipes/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -907,6 +907,15 @@ def __init__(
self._key_prefix = key_prefix

def upload_messages_chunk(self, payload: IO, index: int) -> None:
"""Uploads a chunk of messages to an S3 bucket.
Args:
payload (IO): The payload containing the messages to upload.
index (int): The index of the chunk.
Returns:
None
"""
key = f"{self._key_prefix}/{index}.json" if self._key_prefix else f"{index}.json"
self._client.put_object(
Body=payload.read(),
Expand Down
2 changes: 2 additions & 0 deletions python_modules/dagster/dagster/_config/config_type.py
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,7 @@ def from_python_enum(cls, enum, name=None):
The name for the enum. If not present, `enum.__name__` will be used.
Example:
.. code-block:: python
class Color(enum.Enum):
Expand Down Expand Up @@ -365,6 +366,7 @@ def from_python_enum_direct_values(cls, enum, name=None):
The name for the enum. If not present, `enum.__name__` will be used.
Example:
.. code-block:: python
class Color(enum.Enum):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1086,8 +1086,7 @@ def asset_partitions_time_window_for_output(self, output_name: str) -> TimeWindo
Raises an error if either of the following are true:
- The output asset has no partitioning.
- The output asset is not partitioned with a TimeWindowPartitionsDefinition or a
MultiPartitionsDefinition with one time-partitioned dimension.
- The output asset is not partitioned with a TimeWindowPartitionsDefinition or a MultiPartitionsDefinition with one time-partitioned dimension.
"""
partitions_def = self._partitions_def_for_output(output_name)

Expand Down Expand Up @@ -1156,8 +1155,7 @@ def asset_partitions_time_window_for_input(self, input_name: str) -> TimeWindow:
Raises an error if either of the following are true:
- The input asset has no partitioning.
- The input asset is not partitioned with a TimeWindowPartitionsDefinition or a
MultiPartitionsDefinition with one time-partitioned dimension.
- The input asset is not partitioned with a TimeWindowPartitionsDefinition or a MultiPartitionsDefinition with one time-partitioned dimension.
"""
asset_layer = self.job_def.asset_layer
upstream_asset_key = asset_layer.asset_key_for_input(self.node_handle, input_name)
Expand Down

0 comments on commit 2410489

Please sign in to comment.