-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Automated Release PR --- ## 0.1.0-alpha.2 (2024-06-10) Full Changelog: [v0.1.0-alpha.1...v0.1.0-alpha.2](v0.1.0-alpha.1...v0.1.0-alpha.2) ### Features * **api:** update via SDK Studio ([#4](#4)) ([17b7ce5](17b7ce5)) --- This Pull Request has been generated automatically as part of [Stainless](https://stainlessapi.com/)'s release process. For a better experience, it is recommended to use either rebase-merge or squash-merge when merging this pull request ([see details](https://github.com/stainless-api/release-please/#linear-git-commit-history-use-squash-merge)). _More technical details can be found at [stainless-api/release-please](https://github.com/stainless-api/release-please)_. --------- Co-authored-by: stainless-app[bot] <142633134+stainless-app[bot]@users.noreply.github.com>
- Loading branch information
1 parent
379e17f
commit 16c3a93
Showing
38 changed files
with
423 additions
and
428 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
{ | ||
".": "0.1.0-alpha.1" | ||
".": "0.1.0-alpha.2" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. | ||
|
||
__title__ = "metronome" | ||
__version__ = "0.1.0-alpha.1" # x-release-please-version | ||
__version__ = "0.1.0-alpha.2" # x-release-please-version |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. | ||
|
||
from typing import List, Generic, TypeVar, Optional | ||
from typing_extensions import override | ||
|
||
from ._base_client import BasePage, PageInfo, BaseSyncPage, BaseAsyncPage | ||
|
||
__all__ = ["SyncCursorPage", "AsyncCursorPage"] | ||
|
||
_T = TypeVar("_T") | ||
|
||
|
||
class SyncCursorPage(BaseSyncPage[_T], BasePage[_T], Generic[_T]): | ||
next_page: Optional[str] = None | ||
"""Cursor to fetch the next page""" | ||
data: List[_T] | ||
"""Items of the page""" | ||
|
||
@override | ||
def _get_page_items(self) -> List[_T]: | ||
data = self.data | ||
if not data: | ||
return [] | ||
return data | ||
|
||
@override | ||
def next_page_info(self) -> Optional[PageInfo]: | ||
next_page = self.next_page | ||
if not next_page: | ||
return None | ||
|
||
return PageInfo(params={"next_page": next_page}) | ||
|
||
|
||
class AsyncCursorPage(BaseAsyncPage[_T], BasePage[_T], Generic[_T]): | ||
next_page: Optional[str] = None | ||
"""Cursor to fetch the next page""" | ||
data: List[_T] | ||
"""Items of the page""" | ||
|
||
@override | ||
def _get_page_items(self) -> List[_T]: | ||
data = self.data | ||
if not data: | ||
return [] | ||
return data | ||
|
||
@override | ||
def next_page_info(self) -> Optional[PageInfo]: | ||
next_page = self.next_page | ||
if not next_page: | ||
return None | ||
|
||
return PageInfo(params={"next_page": next_page}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.