Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "0.1.0-alpha.14"
".": "0.1.0-alpha.15"
}
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 7
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel%2Fkernel-c9d64df733f286f09d2203f4e3d820ce57e8d4c629c5e2db4e2bfac91fbc1598.yml
openapi_spec_hash: fa407611fc566d55f403864fbfaa6c23
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/kernel%2Fkernel-39aa058a60035c34a636e7f580b4b9c76b05400ae401ef04a761572b20a5425b.yml
openapi_spec_hash: bb79a204f9edb6b6ccfe783a0a82a423
config_hash: 4dfa4d870ce0e23e31ce33ab6a53dd21
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
# Changelog

## 0.1.0-alpha.15 (2025-05-20)

Full Changelog: [v0.1.0-alpha.14...v0.1.0-alpha.15](https://github.com/onkernel/kernel-python-sdk/compare/v0.1.0-alpha.14...v0.1.0-alpha.15)

### Features

* **api:** update via SDK Studio ([085cf7c](https://github.com/onkernel/kernel-python-sdk/commit/085cf7cd9c68bdef67f360a21f9bd6750483001b))
* **api:** update via SDK Studio ([da4cc1f](https://github.com/onkernel/kernel-python-sdk/commit/da4cc1f1aa385482b0557773845119299b46e270))

## 0.1.0-alpha.14 (2025-05-20)

Full Changelog: [v0.1.0-alpha.13...v0.1.0-alpha.14](https://github.com/onkernel/kernel-python-sdk/compare/v0.1.0-alpha.13...v0.1.0-alpha.14)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "kernel"
version = "0.1.0-alpha.14"
version = "0.1.0-alpha.15"
description = "The official Python library for the kernel API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion src/kernel/_version.py
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__ = "kernel"
__version__ = "0.1.0-alpha.14" # x-release-please-version
__version__ = "0.1.0-alpha.15" # x-release-please-version
10 changes: 7 additions & 3 deletions src/kernel/resources/apps/deployments.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

from __future__ import annotations

from typing import Dict, Mapping, cast
from typing import Any, Dict, Mapping, cast
from typing_extensions import Literal

import httpx
Expand Down Expand Up @@ -145,7 +145,9 @@ def follow(
options=make_request_options(
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
),
cast_to=DeploymentFollowResponse,
cast_to=cast(
Any, DeploymentFollowResponse
), # Union types cannot be passed in as arguments in the type system
stream=True,
stream_cls=Stream[DeploymentFollowResponse],
)
Expand Down Expand Up @@ -270,7 +272,9 @@ async def follow(
options=make_request_options(
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
),
cast_to=DeploymentFollowResponse,
cast_to=cast(
Any, DeploymentFollowResponse
), # Union types cannot be passed in as arguments in the type system
stream=True,
stream_cls=AsyncStream[DeploymentFollowResponse],
)
Expand Down
27 changes: 7 additions & 20 deletions src/kernel/types/apps/deployment_follow_response.py
Original file line number Diff line number Diff line change
@@ -1,22 +1,16 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

from typing import List, Union, Optional
from typing import Union, Optional
from datetime import datetime
from typing_extensions import Literal, Annotated, TypeAlias

from ..._utils import PropertyInfo
from ..._models import BaseModel

__all__ = [
"DeploymentFollowResponse",
"DeploymentFollowResponseItem",
"DeploymentFollowResponseItemStateEvent",
"DeploymentFollowResponseItemStateUpdateEvent",
"DeploymentFollowResponseItemLogEvent",
]
__all__ = ["DeploymentFollowResponse", "StateEvent", "StateUpdateEvent", "LogEvent"]


class DeploymentFollowResponseItemStateEvent(BaseModel):
class StateEvent(BaseModel):
event: Literal["state"]
"""Event type identifier (always "state")."""

Expand All @@ -29,7 +23,7 @@ class DeploymentFollowResponseItemStateEvent(BaseModel):
"""Time the state was reported."""


class DeploymentFollowResponseItemStateUpdateEvent(BaseModel):
class StateUpdateEvent(BaseModel):
event: Literal["state_update"]
"""Event type identifier (always "state_update")."""

Expand All @@ -40,7 +34,7 @@ class DeploymentFollowResponseItemStateUpdateEvent(BaseModel):
"""Time the state change occurred."""


class DeploymentFollowResponseItemLogEvent(BaseModel):
class LogEvent(BaseModel):
event: Literal["log"]
"""Event type identifier (always "log")."""

Expand All @@ -51,13 +45,6 @@ class DeploymentFollowResponseItemLogEvent(BaseModel):
"""Time the log entry was produced."""


DeploymentFollowResponseItem: TypeAlias = Annotated[
Union[
DeploymentFollowResponseItemStateEvent,
DeploymentFollowResponseItemStateUpdateEvent,
DeploymentFollowResponseItemLogEvent,
],
PropertyInfo(discriminator="event"),
DeploymentFollowResponse: TypeAlias = Annotated[
Union[StateEvent, StateUpdateEvent, LogEvent], PropertyInfo(discriminator="event")
]

DeploymentFollowResponse: TypeAlias = List[DeploymentFollowResponseItem]