Skip to content
Draft
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 .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[submodule "sdk-core"]
path = temporalio/bridge/sdk-core
url = https://github.com/temporalio/sdk-core.git
url = https://github.com/jmaeagle99/temporalio-sdk-core.git
2 changes: 2 additions & 0 deletions temporalio/api/activity/v1/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,13 @@
ActivityExecutionListInfo,
ActivityExecutionOutcome,
ActivityOptions,
CallbackInfo,
)

__all__ = [
"ActivityExecutionInfo",
"ActivityExecutionListInfo",
"ActivityExecutionOutcome",
"ActivityOptions",
"CallbackInfo",
]
61 changes: 52 additions & 9 deletions temporalio/api/activity/v1/message_pb2.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

87 changes: 87 additions & 0 deletions temporalio/api/activity/v1/message_pb2.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,16 @@ isort:skip_file
"""

import builtins
import collections.abc
import sys

import google.protobuf.descriptor
import google.protobuf.duration_pb2
import google.protobuf.internal.containers
import google.protobuf.message
import google.protobuf.timestamp_pb2

import temporalio.api.callback.v1.message_pb2
import temporalio.api.common.v1.message_pb2
import temporalio.api.deployment.v1.message_pb2
import temporalio.api.enums.v1.activity_pb2
Expand Down Expand Up @@ -202,6 +205,8 @@ class ActivityExecutionInfo(google.protobuf.message.Message):
HEADER_FIELD_NUMBER: builtins.int
USER_METADATA_FIELD_NUMBER: builtins.int
CANCELED_REASON_FIELD_NUMBER: builtins.int
LINKS_FIELD_NUMBER: builtins.int
TOTAL_HEARTBEAT_COUNT_FIELD_NUMBER: builtins.int
activity_id: builtins.str
"""Unique identifier of this activity within its namespace along with run ID (below)."""
run_id: builtins.str
Expand Down Expand Up @@ -313,6 +318,15 @@ class ActivityExecutionInfo(google.protobuf.message.Message):
"""Metadata for use by user interfaces to display the fixed as-of-start summary and details of the activity."""
canceled_reason: builtins.str
"""Set if activity cancelation was requested."""
@property
def links(
self,
) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[
temporalio.api.common.v1.message_pb2.Link
]:
"""Links to related entities, such as the entity that started this activity."""
total_heartbeat_count: builtins.int
"""Total number of heartbeats recorded across all attempts of this activity, including retries."""
def __init__(
self,
*,
Expand Down Expand Up @@ -353,6 +367,9 @@ class ActivityExecutionInfo(google.protobuf.message.Message):
user_metadata: temporalio.api.sdk.v1.user_metadata_pb2.UserMetadata
| None = ...,
canceled_reason: builtins.str = ...,
links: collections.abc.Iterable[temporalio.api.common.v1.message_pb2.Link]
| None = ...,
total_heartbeat_count: builtins.int = ...,
) -> None: ...
def HasField(
self,
Expand Down Expand Up @@ -440,6 +457,8 @@ class ActivityExecutionInfo(google.protobuf.message.Message):
b"last_started_time",
"last_worker_identity",
b"last_worker_identity",
"links",
b"links",
"next_attempt_schedule_time",
b"next_attempt_schedule_time",
"priority",
Expand Down Expand Up @@ -468,6 +487,8 @@ class ActivityExecutionInfo(google.protobuf.message.Message):
b"status",
"task_queue",
b"task_queue",
"total_heartbeat_count",
b"total_heartbeat_count",
"user_metadata",
b"user_metadata",
],
Expand Down Expand Up @@ -587,3 +608,69 @@ class ActivityExecutionListInfo(google.protobuf.message.Message):
) -> None: ...

global___ActivityExecutionListInfo = ActivityExecutionListInfo

class CallbackInfo(google.protobuf.message.Message):
"""CallbackInfo contains the state of an attached activity callback."""

DESCRIPTOR: google.protobuf.descriptor.Descriptor

class ActivityClosed(google.protobuf.message.Message):
"""Trigger for when the activity is closed."""

DESCRIPTOR: google.protobuf.descriptor.Descriptor

def __init__(
self,
) -> None: ...

class Trigger(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor

ACTIVITY_CLOSED_FIELD_NUMBER: builtins.int
@property
def activity_closed(self) -> global___CallbackInfo.ActivityClosed: ...
def __init__(
self,
*,
activity_closed: global___CallbackInfo.ActivityClosed | None = ...,
) -> None: ...
def HasField(
self,
field_name: typing_extensions.Literal[
"activity_closed", b"activity_closed", "variant", b"variant"
],
) -> builtins.bool: ...
def ClearField(
self,
field_name: typing_extensions.Literal[
"activity_closed", b"activity_closed", "variant", b"variant"
],
) -> None: ...
def WhichOneof(
self, oneof_group: typing_extensions.Literal["variant", b"variant"]
) -> typing_extensions.Literal["activity_closed"] | None: ...

TRIGGER_FIELD_NUMBER: builtins.int
INFO_FIELD_NUMBER: builtins.int
@property
def trigger(self) -> global___CallbackInfo.Trigger:
"""Trigger for this callback."""
@property
def info(self) -> temporalio.api.callback.v1.message_pb2.CallbackInfo:
"""Common callback info."""
def __init__(
self,
*,
trigger: global___CallbackInfo.Trigger | None = ...,
info: temporalio.api.callback.v1.message_pb2.CallbackInfo | None = ...,
) -> None: ...
def HasField(
self,
field_name: typing_extensions.Literal["info", b"info", "trigger", b"trigger"],
) -> builtins.bool: ...
def ClearField(
self,
field_name: typing_extensions.Literal["info", b"info", "trigger", b"trigger"],
) -> None: ...

global___CallbackInfo = CallbackInfo
Empty file.
5 changes: 5 additions & 0 deletions temporalio/api/callback/v1/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
from .message_pb2 import CallbackInfo

__all__ = [
"CallbackInfo",
]
Loading
Loading