Skip to content

Commit

Permalink
add autogen files
Browse files Browse the repository at this point in the history
  • Loading branch information
martha-johnston committed May 29, 2024
1 parent 30a4313 commit 3461876
Show file tree
Hide file tree
Showing 61 changed files with 1,789 additions and 1,411 deletions.
10 changes: 9 additions & 1 deletion src/viam/gen/app/v1/app_grpc.py

Large diffs are not rendered by default.

368 changes: 189 additions & 179 deletions src/viam/gen/app/v1/app_pb2.py

Large diffs are not rendered by default.

94 changes: 87 additions & 7 deletions src/viam/gen/app/v1/app_pb2.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,25 @@ else:
import typing_extensions
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor

class _FragmentVisibility:
ValueType = typing.NewType('ValueType', builtins.int)
V: typing_extensions.TypeAlias = ValueType

class _FragmentVisibilityEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_FragmentVisibility.ValueType], builtins.type):
DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
FRAGMENT_VISIBILITY_UNSPECIFIED: _FragmentVisibility.ValueType
FRAGMENT_VISIBILITY_PRIVATE: _FragmentVisibility.ValueType
FRAGMENT_VISIBILITY_PUBLIC: _FragmentVisibility.ValueType
FRAGMENT_VISIBILITY_PUBLIC_UNLISTED: _FragmentVisibility.ValueType

class FragmentVisibility(_FragmentVisibility, metaclass=_FragmentVisibilityEnumTypeWrapper):
...
FRAGMENT_VISIBILITY_UNSPECIFIED: FragmentVisibility.ValueType
FRAGMENT_VISIBILITY_PRIVATE: FragmentVisibility.ValueType
FRAGMENT_VISIBILITY_PUBLIC: FragmentVisibility.ValueType
FRAGMENT_VISIBILITY_PUBLIC_UNLISTED: FragmentVisibility.ValueType
global___FragmentVisibility = FragmentVisibility

class _RegistryItemStatus:
ValueType = typing.NewType('ValueType', builtins.int)
V: typing_extensions.TypeAlias = ValueType
Expand Down Expand Up @@ -1619,6 +1638,7 @@ class Fragment(google.protobuf.message.Message):
ROBOT_PART_COUNT_FIELD_NUMBER: builtins.int
ORGANIZATION_COUNT_FIELD_NUMBER: builtins.int
ONLY_USED_BY_OWNER_FIELD_NUMBER: builtins.int
VISIBILITY_FIELD_NUMBER: builtins.int
id: builtins.str
name: builtins.str
organization_owner: builtins.str
Expand All @@ -1630,6 +1650,8 @@ class Fragment(google.protobuf.message.Message):
'number of organizations using this fragment'
only_used_by_owner: builtins.bool
'whether the organization(s) using this fragment is the same as the fragment org'
visibility: global___FragmentVisibility.ValueType
'the visibility of a fragment; public, private or unlisted'

@property
def fragment(self) -> google.protobuf.struct_pb2.Struct:
Expand All @@ -1639,13 +1661,13 @@ class Fragment(google.protobuf.message.Message):
def created_on(self) -> google.protobuf.timestamp_pb2.Timestamp:
...

def __init__(self, *, id: builtins.str=..., name: builtins.str=..., fragment: google.protobuf.struct_pb2.Struct | None=..., organization_owner: builtins.str=..., public: builtins.bool=..., created_on: google.protobuf.timestamp_pb2.Timestamp | None=..., organization_name: builtins.str=..., robot_part_count: builtins.int=..., organization_count: builtins.int=..., only_used_by_owner: builtins.bool=...) -> None:
def __init__(self, *, id: builtins.str=..., name: builtins.str=..., fragment: google.protobuf.struct_pb2.Struct | None=..., organization_owner: builtins.str=..., public: builtins.bool=..., created_on: google.protobuf.timestamp_pb2.Timestamp | None=..., organization_name: builtins.str=..., robot_part_count: builtins.int=..., organization_count: builtins.int=..., only_used_by_owner: builtins.bool=..., visibility: global___FragmentVisibility.ValueType=...) -> None:
...

def HasField(self, field_name: typing.Literal['created_on', b'created_on', 'fragment', b'fragment']) -> builtins.bool:
...

def ClearField(self, field_name: typing.Literal['created_on', b'created_on', 'fragment', b'fragment', 'id', b'id', 'name', b'name', 'only_used_by_owner', b'only_used_by_owner', 'organization_count', b'organization_count', 'organization_name', b'organization_name', 'organization_owner', b'organization_owner', 'public', b'public', 'robot_part_count', b'robot_part_count']) -> None:
def ClearField(self, field_name: typing.Literal['created_on', b'created_on', 'fragment', b'fragment', 'id', b'id', 'name', b'name', 'only_used_by_owner', b'only_used_by_owner', 'organization_count', b'organization_count', 'organization_name', b'organization_name', 'organization_owner', b'organization_owner', 'public', b'public', 'robot_part_count', b'robot_part_count', 'visibility', b'visibility']) -> None:
...
global___Fragment = Fragment

Expand Down Expand Up @@ -1761,25 +1783,32 @@ class UpdateFragmentRequest(google.protobuf.message.Message):
NAME_FIELD_NUMBER: builtins.int
CONFIG_FIELD_NUMBER: builtins.int
PUBLIC_FIELD_NUMBER: builtins.int
VISIBILITY_FIELD_NUMBER: builtins.int
id: builtins.str
name: builtins.str
public: builtins.bool
visibility: global___FragmentVisibility.ValueType

@property
def config(self) -> google.protobuf.struct_pb2.Struct:
...

def __init__(self, *, id: builtins.str=..., name: builtins.str=..., config: google.protobuf.struct_pb2.Struct | None=..., public: builtins.bool | None=...) -> None:
def __init__(self, *, id: builtins.str=..., name: builtins.str=..., config: google.protobuf.struct_pb2.Struct | None=..., public: builtins.bool | None=..., visibility: global___FragmentVisibility.ValueType | None=...) -> None:
...

def HasField(self, field_name: typing.Literal['_public', b'_public', 'config', b'config', 'public', b'public']) -> builtins.bool:
def HasField(self, field_name: typing.Literal['_public', b'_public', '_visibility', b'_visibility', 'config', b'config', 'public', b'public', 'visibility', b'visibility']) -> builtins.bool:
...

def ClearField(self, field_name: typing.Literal['_public', b'_public', 'config', b'config', 'id', b'id', 'name', b'name', 'public', b'public']) -> None:
def ClearField(self, field_name: typing.Literal['_public', b'_public', '_visibility', b'_visibility', 'config', b'config', 'id', b'id', 'name', b'name', 'public', b'public', 'visibility', b'visibility']) -> None:
...

@typing.overload
def WhichOneof(self, oneof_group: typing.Literal['_public', b'_public']) -> typing.Literal['public'] | None:
...

@typing.overload
def WhichOneof(self, oneof_group: typing.Literal['_visibility', b'_visibility']) -> typing.Literal['visibility'] | None:
...
global___UpdateFragmentRequest = UpdateFragmentRequest

@typing.final
Expand Down Expand Up @@ -2300,6 +2329,27 @@ class MLModelMetadata(google.protobuf.message.Message):
...
global___MLModelMetadata = MLModelMetadata

@typing.final
class MLTrainingVersion(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
VERSION_FIELD_NUMBER: builtins.int
CREATED_ON_FIELD_NUMBER: builtins.int
version: builtins.str

@property
def created_on(self) -> google.protobuf.timestamp_pb2.Timestamp:
...

def __init__(self, *, version: builtins.str=..., created_on: google.protobuf.timestamp_pb2.Timestamp | None=...) -> None:
...

def HasField(self, field_name: typing.Literal['created_on', b'created_on']) -> builtins.bool:
...

def ClearField(self, field_name: typing.Literal['created_on', b'created_on', 'version', b'version']) -> None:
...
global___MLTrainingVersion = MLTrainingVersion

@typing.final
class MLTrainingMetadata(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
Expand All @@ -2312,10 +2362,10 @@ class MLTrainingMetadata(google.protobuf.message.Message):
draft: builtins.bool

@property
def versions(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
def versions(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___MLTrainingVersion]:
"""A list of package versions for ML training source distribution"""

def __init__(self, *, versions: collections.abc.Iterable[builtins.str] | None=..., model_type: app.mltraining.v1.ml_training_pb2.ModelType.ValueType=..., model_framework: app.mltraining.v1.ml_training_pb2.ModelFramework.ValueType=..., draft: builtins.bool=...) -> None:
def __init__(self, *, versions: collections.abc.Iterable[global___MLTrainingVersion] | None=..., model_type: app.mltraining.v1.ml_training_pb2.ModelType.ValueType=..., model_framework: app.mltraining.v1.ml_training_pb2.ModelFramework.ValueType=..., draft: builtins.bool=...) -> None:
...

def ClearField(self, field_name: typing.Literal['draft', b'draft', 'model_framework', b'model_framework', 'model_type', b'model_type', 'versions', b'versions']) -> None:
Expand Down Expand Up @@ -3034,6 +3084,36 @@ class DeleteKeyResponse(google.protobuf.message.Message):
...
global___DeleteKeyResponse = DeleteKeyResponse

@typing.final
class RenameKeyRequest(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
ID_FIELD_NUMBER: builtins.int
NAME_FIELD_NUMBER: builtins.int
id: builtins.str
name: builtins.str

def __init__(self, *, id: builtins.str=..., name: builtins.str=...) -> None:
...

def ClearField(self, field_name: typing.Literal['id', b'id', 'name', b'name']) -> None:
...
global___RenameKeyRequest = RenameKeyRequest

@typing.final
class RenameKeyResponse(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
ID_FIELD_NUMBER: builtins.int
NAME_FIELD_NUMBER: builtins.int
id: builtins.str
name: builtins.str

def __init__(self, *, id: builtins.str=..., name: builtins.str=...) -> None:
...

def ClearField(self, field_name: typing.Literal['id', b'id', 'name', b'name']) -> None:
...
global___RenameKeyResponse = RenameKeyResponse

@typing.final
class AuthorizationDetails(google.protobuf.message.Message):
DESCRIPTOR: google.protobuf.descriptor.Descriptor
Expand Down
12 changes: 10 additions & 2 deletions src/viam/gen/app/v1/end_user_grpc.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,12 @@ async def RegisterAuthApplication(self, stream: 'grpclib.server.Stream[app.v1.en
async def UpdateAuthApplication(self, stream: 'grpclib.server.Stream[app.v1.end_user_pb2.UpdateAuthApplicationRequest, app.v1.end_user_pb2.UpdateAuthApplicationResponse]') -> None:
pass

@abc.abstractmethod
async def GetAuthApplication(self, stream: 'grpclib.server.Stream[app.v1.end_user_pb2.GetAuthApplicationRequest, app.v1.end_user_pb2.GetAuthApplicationResponse]') -> None:
pass

def __mapping__(self) -> typing.Dict[str, grpclib.const.Handler]:
return {'/viam.app.v1.EndUserService/IsLegalAccepted': grpclib.const.Handler(self.IsLegalAccepted, grpclib.const.Cardinality.UNARY_UNARY, app.v1.end_user_pb2.IsLegalAcceptedRequest, app.v1.end_user_pb2.IsLegalAcceptedResponse), '/viam.app.v1.EndUserService/AcceptLegal': grpclib.const.Handler(self.AcceptLegal, grpclib.const.Cardinality.UNARY_UNARY, app.v1.end_user_pb2.AcceptLegalRequest, app.v1.end_user_pb2.AcceptLegalResponse), '/viam.app.v1.EndUserService/RegisterAuthApplication': grpclib.const.Handler(self.RegisterAuthApplication, grpclib.const.Cardinality.UNARY_UNARY, app.v1.end_user_pb2.RegisterAuthApplicationRequest, app.v1.end_user_pb2.RegisterAuthApplicationResponse), '/viam.app.v1.EndUserService/UpdateAuthApplication': grpclib.const.Handler(self.UpdateAuthApplication, grpclib.const.Cardinality.UNARY_UNARY, app.v1.end_user_pb2.UpdateAuthApplicationRequest, app.v1.end_user_pb2.UpdateAuthApplicationResponse)}
return {'/viam.app.v1.EndUserService/IsLegalAccepted': grpclib.const.Handler(self.IsLegalAccepted, grpclib.const.Cardinality.UNARY_UNARY, app.v1.end_user_pb2.IsLegalAcceptedRequest, app.v1.end_user_pb2.IsLegalAcceptedResponse), '/viam.app.v1.EndUserService/AcceptLegal': grpclib.const.Handler(self.AcceptLegal, grpclib.const.Cardinality.UNARY_UNARY, app.v1.end_user_pb2.AcceptLegalRequest, app.v1.end_user_pb2.AcceptLegalResponse), '/viam.app.v1.EndUserService/RegisterAuthApplication': grpclib.const.Handler(self.RegisterAuthApplication, grpclib.const.Cardinality.UNARY_UNARY, app.v1.end_user_pb2.RegisterAuthApplicationRequest, app.v1.end_user_pb2.RegisterAuthApplicationResponse), '/viam.app.v1.EndUserService/UpdateAuthApplication': grpclib.const.Handler(self.UpdateAuthApplication, grpclib.const.Cardinality.UNARY_UNARY, app.v1.end_user_pb2.UpdateAuthApplicationRequest, app.v1.end_user_pb2.UpdateAuthApplicationResponse), '/viam.app.v1.EndUserService/GetAuthApplication': grpclib.const.Handler(self.GetAuthApplication, grpclib.const.Cardinality.UNARY_UNARY, app.v1.end_user_pb2.GetAuthApplicationRequest, app.v1.end_user_pb2.GetAuthApplicationResponse)}

class UnimplementedEndUserServiceBase(EndUserServiceBase):

Expand All @@ -42,10 +46,14 @@ async def RegisterAuthApplication(self, stream: 'grpclib.server.Stream[app.v1.en
async def UpdateAuthApplication(self, stream: 'grpclib.server.Stream[app.v1.end_user_pb2.UpdateAuthApplicationRequest, app.v1.end_user_pb2.UpdateAuthApplicationResponse]') -> None:
raise grpclib.exceptions.GRPCError(grpclib.const.Status.UNIMPLEMENTED)

async def GetAuthApplication(self, stream: 'grpclib.server.Stream[app.v1.end_user_pb2.GetAuthApplicationRequest, app.v1.end_user_pb2.GetAuthApplicationResponse]') -> None:
raise grpclib.exceptions.GRPCError(grpclib.const.Status.UNIMPLEMENTED)

class EndUserServiceStub:

def __init__(self, channel: grpclib.client.Channel) -> None:
self.IsLegalAccepted = grpclib.client.UnaryUnaryMethod(channel, '/viam.app.v1.EndUserService/IsLegalAccepted', app.v1.end_user_pb2.IsLegalAcceptedRequest, app.v1.end_user_pb2.IsLegalAcceptedResponse)
self.AcceptLegal = grpclib.client.UnaryUnaryMethod(channel, '/viam.app.v1.EndUserService/AcceptLegal', app.v1.end_user_pb2.AcceptLegalRequest, app.v1.end_user_pb2.AcceptLegalResponse)
self.RegisterAuthApplication = grpclib.client.UnaryUnaryMethod(channel, '/viam.app.v1.EndUserService/RegisterAuthApplication', app.v1.end_user_pb2.RegisterAuthApplicationRequest, app.v1.end_user_pb2.RegisterAuthApplicationResponse)
self.UpdateAuthApplication = grpclib.client.UnaryUnaryMethod(channel, '/viam.app.v1.EndUserService/UpdateAuthApplication', app.v1.end_user_pb2.UpdateAuthApplicationRequest, app.v1.end_user_pb2.UpdateAuthApplicationResponse)
self.UpdateAuthApplication = grpclib.client.UnaryUnaryMethod(channel, '/viam.app.v1.EndUserService/UpdateAuthApplication', app.v1.end_user_pb2.UpdateAuthApplicationRequest, app.v1.end_user_pb2.UpdateAuthApplicationResponse)
self.GetAuthApplication = grpclib.client.UnaryUnaryMethod(channel, '/viam.app.v1.EndUserService/GetAuthApplication', app.v1.end_user_pb2.GetAuthApplicationRequest, app.v1.end_user_pb2.GetAuthApplicationResponse)
Loading

0 comments on commit 3461876

Please sign in to comment.