diff --git a/pymapadmin/grpc/admin_pb2.py b/pymapadmin/grpc/admin_pb2.py index 0aedfa1..84d0e10 100644 --- a/pymapadmin/grpc/admin_pb2.py +++ b/pymapadmin/grpc/admin_pb2.py @@ -4,6 +4,7 @@ """Generated protocol buffer code.""" from google.protobuf.internal import enum_type_wrapper from google.protobuf import descriptor as _descriptor +from google.protobuf import descriptor_pool as _descriptor_pool from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import symbol_database as _symbol_database @@ -14,711 +15,27 @@ -DESCRIPTOR = _descriptor.FileDescriptor( - name='pymapadmin/grpc/admin.proto', - package='pymapadmin.grpc', - syntax='proto3', - serialized_options=None, - create_key=_descriptor._internal_create_key, - serialized_pb=b'\n\x1bpymapadmin/grpc/admin.proto\x12\x0fpymapadmin.grpc\"R\n\x06Result\x12)\n\x04\x63ode\x18\x01 \x01(\x0e\x32\x1b.pymapadmin.grpc.ResultCode\x12\x10\n\x08response\x18\x02 \x01(\x0c\x12\x0b\n\x03key\x18\x03 \x01(\t\"\x85\x01\n\x0cLoginRequest\x12\x0f\n\x07\x61uthcid\x18\x01 \x01(\t\x12\x0e\n\x06secret\x18\x02 \x01(\t\x12\x14\n\x07\x61uthzid\x18\x03 \x01(\tH\x00\x88\x01\x01\x12\x1d\n\x10token_expiration\x18\x04 \x01(\x01H\x01\x88\x01\x01\x42\n\n\x08_authzidB\x13\n\x11_token_expiration\"d\n\rLoginResponse\x12\'\n\x06result\x18\x01 \x01(\x0b\x32\x17.pymapadmin.grpc.Result\x12\x19\n\x0c\x62\x65\x61rer_token\x18\x02 \x01(\tH\x00\x88\x01\x01\x42\x0f\n\r_bearer_token\"\r\n\x0bPingRequest\"k\n\x0cPingResponse\x12\'\n\x06result\x18\x01 \x01(\x0b\x32\x17.pymapadmin.grpc.Result\x12\x15\n\rpymap_version\x18\x02 \x01(\t\x12\x1b\n\x13pymap_admin_version\x18\x03 \x01(\t\"\xb0\x01\n\rAppendRequest\x12\x0c\n\x04user\x18\x01 \x01(\t\x12\x13\n\x06sender\x18\x02 \x01(\tH\x00\x88\x01\x01\x12\x16\n\trecipient\x18\x03 \x01(\tH\x01\x88\x01\x01\x12\x14\n\x07mailbox\x18\x04 \x01(\tH\x02\x88\x01\x01\x12\x0c\n\x04\x64\x61ta\x18\x05 \x01(\x0c\x12\r\n\x05\x66lags\x18\x06 \x03(\t\x12\x0c\n\x04when\x18\x07 \x01(\x04\x42\t\n\x07_senderB\x0c\n\n_recipientB\n\n\x08_mailbox\"\x88\x01\n\x0e\x41ppendResponse\x12\'\n\x06result\x18\x01 \x01(\x0b\x32\x17.pymapadmin.grpc.Result\x12\x0f\n\x07mailbox\x18\x02 \x01(\t\x12\x15\n\x08validity\x18\x03 \x01(\rH\x00\x88\x01\x01\x12\x10\n\x03uid\x18\x04 \x01(\rH\x01\x88\x01\x01\x42\x0b\n\t_validityB\x06\n\x04_uid\"\x94\x01\n\x08UserData\x12\x15\n\x08password\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x35\n\x06params\x18\x02 \x03(\x0b\x32%.pymapadmin.grpc.UserData.ParamsEntry\x1a-\n\x0bParamsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x42\x0b\n\t_password\"\x1e\n\x0eGetUserRequest\x12\x0c\n\x04user\x18\x01 \x01(\t\"G\n\x0eSetUserRequest\x12\x0c\n\x04user\x18\x01 \x01(\t\x12\'\n\x04\x64\x61ta\x18\x02 \x01(\x0b\x32\x19.pymapadmin.grpc.UserData\"!\n\x11\x44\x65leteUserRequest\x12\x0c\n\x04user\x18\x01 \x01(\t\"\x84\x01\n\x0cUserResponse\x12\'\n\x06result\x18\x01 \x01(\x0b\x32\x17.pymapadmin.grpc.Result\x12\x15\n\x08username\x18\x02 \x01(\tH\x00\x88\x01\x01\x12\'\n\x04\x64\x61ta\x18\x03 \x01(\x0b\x32\x19.pymapadmin.grpc.UserDataB\x0b\n\t_username*&\n\nResultCode\x12\x0b\n\x07SUCCESS\x10\x00\x12\x0b\n\x07\x46\x41ILURE\x10\x01\x32\x99\x01\n\x06System\x12\x45\n\x04Ping\x12\x1c.pymapadmin.grpc.PingRequest\x1a\x1d.pymapadmin.grpc.PingResponse\"\x00\x12H\n\x05Login\x12\x1d.pymapadmin.grpc.LoginRequest\x1a\x1e.pymapadmin.grpc.LoginResponse\"\x00\x32V\n\x07Mailbox\x12K\n\x06\x41ppend\x12\x1e.pymapadmin.grpc.AppendRequest\x1a\x1f.pymapadmin.grpc.AppendResponse\"\x00\x32\xf3\x01\n\x04User\x12K\n\x07GetUser\x12\x1f.pymapadmin.grpc.GetUserRequest\x1a\x1d.pymapadmin.grpc.UserResponse\"\x00\x12K\n\x07SetUser\x12\x1f.pymapadmin.grpc.SetUserRequest\x1a\x1d.pymapadmin.grpc.UserResponse\"\x00\x12Q\n\nDeleteUser\x12\".pymapadmin.grpc.DeleteUserRequest\x1a\x1d.pymapadmin.grpc.UserResponse\"\x00\x62\x06proto3' -) - -_RESULTCODE = _descriptor.EnumDescriptor( - name='ResultCode', - full_name='pymapadmin.grpc.ResultCode', - filename=None, - file=DESCRIPTOR, - create_key=_descriptor._internal_create_key, - values=[ - _descriptor.EnumValueDescriptor( - name='SUCCESS', index=0, number=0, - serialized_options=None, - type=None, - create_key=_descriptor._internal_create_key), - _descriptor.EnumValueDescriptor( - name='FAILURE', index=1, number=1, - serialized_options=None, - type=None, - create_key=_descriptor._internal_create_key), - ], - containing_type=None, - serialized_options=None, - serialized_start=1238, - serialized_end=1276, -) -_sym_db.RegisterEnumDescriptor(_RESULTCODE) +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1bpymapadmin/grpc/admin.proto\x12\x0fpymapadmin.grpc\"R\n\x06Result\x12)\n\x04\x63ode\x18\x01 \x01(\x0e\x32\x1b.pymapadmin.grpc.ResultCode\x12\x10\n\x08response\x18\x02 \x01(\x0c\x12\x0b\n\x03key\x18\x03 \x01(\t\"\x85\x01\n\x0cLoginRequest\x12\x0f\n\x07\x61uthcid\x18\x01 \x01(\t\x12\x0e\n\x06secret\x18\x02 \x01(\t\x12\x14\n\x07\x61uthzid\x18\x03 \x01(\tH\x00\x88\x01\x01\x12\x1d\n\x10token_expiration\x18\x04 \x01(\x01H\x01\x88\x01\x01\x42\n\n\x08_authzidB\x13\n\x11_token_expiration\"d\n\rLoginResponse\x12\'\n\x06result\x18\x01 \x01(\x0b\x32\x17.pymapadmin.grpc.Result\x12\x19\n\x0c\x62\x65\x61rer_token\x18\x02 \x01(\tH\x00\x88\x01\x01\x42\x0f\n\r_bearer_token\"\r\n\x0bPingRequest\"k\n\x0cPingResponse\x12\'\n\x06result\x18\x01 \x01(\x0b\x32\x17.pymapadmin.grpc.Result\x12\x15\n\rpymap_version\x18\x02 \x01(\t\x12\x1b\n\x13pymap_admin_version\x18\x03 \x01(\t\"\xb0\x01\n\rAppendRequest\x12\x0c\n\x04user\x18\x01 \x01(\t\x12\x13\n\x06sender\x18\x02 \x01(\tH\x00\x88\x01\x01\x12\x16\n\trecipient\x18\x03 \x01(\tH\x01\x88\x01\x01\x12\x14\n\x07mailbox\x18\x04 \x01(\tH\x02\x88\x01\x01\x12\x0c\n\x04\x64\x61ta\x18\x05 \x01(\x0c\x12\r\n\x05\x66lags\x18\x06 \x03(\t\x12\x0c\n\x04when\x18\x07 \x01(\x04\x42\t\n\x07_senderB\x0c\n\n_recipientB\n\n\x08_mailbox\"\x88\x01\n\x0e\x41ppendResponse\x12\'\n\x06result\x18\x01 \x01(\x0b\x32\x17.pymapadmin.grpc.Result\x12\x0f\n\x07mailbox\x18\x02 \x01(\t\x12\x15\n\x08validity\x18\x03 \x01(\rH\x00\x88\x01\x01\x12\x10\n\x03uid\x18\x04 \x01(\rH\x01\x88\x01\x01\x42\x0b\n\t_validityB\x06\n\x04_uid\"\x94\x01\n\x08UserData\x12\x15\n\x08password\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x35\n\x06params\x18\x02 \x03(\x0b\x32%.pymapadmin.grpc.UserData.ParamsEntry\x1a-\n\x0bParamsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x42\x0b\n\t_password\"\x1e\n\x0eGetUserRequest\x12\x0c\n\x04user\x18\x01 \x01(\t\"G\n\x0eSetUserRequest\x12\x0c\n\x04user\x18\x01 \x01(\t\x12\'\n\x04\x64\x61ta\x18\x02 \x01(\x0b\x32\x19.pymapadmin.grpc.UserData\"!\n\x11\x44\x65leteUserRequest\x12\x0c\n\x04user\x18\x01 \x01(\t\"\x84\x01\n\x0cUserResponse\x12\'\n\x06result\x18\x01 \x01(\x0b\x32\x17.pymapadmin.grpc.Result\x12\x15\n\x08username\x18\x02 \x01(\tH\x00\x88\x01\x01\x12\'\n\x04\x64\x61ta\x18\x03 \x01(\x0b\x32\x19.pymapadmin.grpc.UserDataB\x0b\n\t_username*&\n\nResultCode\x12\x0b\n\x07SUCCESS\x10\x00\x12\x0b\n\x07\x46\x41ILURE\x10\x01\x32\x99\x01\n\x06System\x12\x45\n\x04Ping\x12\x1c.pymapadmin.grpc.PingRequest\x1a\x1d.pymapadmin.grpc.PingResponse\"\x00\x12H\n\x05Login\x12\x1d.pymapadmin.grpc.LoginRequest\x1a\x1e.pymapadmin.grpc.LoginResponse\"\x00\x32V\n\x07Mailbox\x12K\n\x06\x41ppend\x12\x1e.pymapadmin.grpc.AppendRequest\x1a\x1f.pymapadmin.grpc.AppendResponse\"\x00\x32\xf3\x01\n\x04User\x12K\n\x07GetUser\x12\x1f.pymapadmin.grpc.GetUserRequest\x1a\x1d.pymapadmin.grpc.UserResponse\"\x00\x12K\n\x07SetUser\x12\x1f.pymapadmin.grpc.SetUserRequest\x1a\x1d.pymapadmin.grpc.UserResponse\"\x00\x12Q\n\nDeleteUser\x12\".pymapadmin.grpc.DeleteUserRequest\x1a\x1d.pymapadmin.grpc.UserResponse\"\x00\x62\x06proto3') +_RESULTCODE = DESCRIPTOR.enum_types_by_name['ResultCode'] ResultCode = enum_type_wrapper.EnumTypeWrapper(_RESULTCODE) SUCCESS = 0 FAILURE = 1 - -_RESULT = _descriptor.Descriptor( - name='Result', - full_name='pymapadmin.grpc.Result', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - _descriptor.FieldDescriptor( - name='code', full_name='pymapadmin.grpc.Result.code', index=0, - number=1, type=14, cpp_type=8, label=1, - has_default_value=False, default_value=0, - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='response', full_name='pymapadmin.grpc.Result.response', index=1, - number=2, type=12, cpp_type=9, label=1, - has_default_value=False, default_value=b"", - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='key', full_name='pymapadmin.grpc.Result.key', index=2, - number=3, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - ], - serialized_start=48, - serialized_end=130, -) - - -_LOGINREQUEST = _descriptor.Descriptor( - name='LoginRequest', - full_name='pymapadmin.grpc.LoginRequest', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - _descriptor.FieldDescriptor( - name='authcid', full_name='pymapadmin.grpc.LoginRequest.authcid', index=0, - number=1, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='secret', full_name='pymapadmin.grpc.LoginRequest.secret', index=1, - number=2, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='authzid', full_name='pymapadmin.grpc.LoginRequest.authzid', index=2, - number=3, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='token_expiration', full_name='pymapadmin.grpc.LoginRequest.token_expiration', index=3, - number=4, type=1, cpp_type=5, label=1, - has_default_value=False, default_value=float(0), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - _descriptor.OneofDescriptor( - name='_authzid', full_name='pymapadmin.grpc.LoginRequest._authzid', - index=0, containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[]), - _descriptor.OneofDescriptor( - name='_token_expiration', full_name='pymapadmin.grpc.LoginRequest._token_expiration', - index=1, containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[]), - ], - serialized_start=133, - serialized_end=266, -) - - -_LOGINRESPONSE = _descriptor.Descriptor( - name='LoginResponse', - full_name='pymapadmin.grpc.LoginResponse', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - _descriptor.FieldDescriptor( - name='result', full_name='pymapadmin.grpc.LoginResponse.result', index=0, - number=1, type=11, cpp_type=10, label=1, - has_default_value=False, default_value=None, - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='bearer_token', full_name='pymapadmin.grpc.LoginResponse.bearer_token', index=1, - number=2, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - _descriptor.OneofDescriptor( - name='_bearer_token', full_name='pymapadmin.grpc.LoginResponse._bearer_token', - index=0, containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[]), - ], - serialized_start=268, - serialized_end=368, -) - - -_PINGREQUEST = _descriptor.Descriptor( - name='PingRequest', - full_name='pymapadmin.grpc.PingRequest', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - ], - serialized_start=370, - serialized_end=383, -) - - -_PINGRESPONSE = _descriptor.Descriptor( - name='PingResponse', - full_name='pymapadmin.grpc.PingResponse', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - _descriptor.FieldDescriptor( - name='result', full_name='pymapadmin.grpc.PingResponse.result', index=0, - number=1, type=11, cpp_type=10, label=1, - has_default_value=False, default_value=None, - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='pymap_version', full_name='pymapadmin.grpc.PingResponse.pymap_version', index=1, - number=2, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='pymap_admin_version', full_name='pymapadmin.grpc.PingResponse.pymap_admin_version', index=2, - number=3, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - ], - serialized_start=385, - serialized_end=492, -) - - -_APPENDREQUEST = _descriptor.Descriptor( - name='AppendRequest', - full_name='pymapadmin.grpc.AppendRequest', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - _descriptor.FieldDescriptor( - name='user', full_name='pymapadmin.grpc.AppendRequest.user', index=0, - number=1, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='sender', full_name='pymapadmin.grpc.AppendRequest.sender', index=1, - number=2, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='recipient', full_name='pymapadmin.grpc.AppendRequest.recipient', index=2, - number=3, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='mailbox', full_name='pymapadmin.grpc.AppendRequest.mailbox', index=3, - number=4, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='data', full_name='pymapadmin.grpc.AppendRequest.data', index=4, - number=5, type=12, cpp_type=9, label=1, - has_default_value=False, default_value=b"", - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='flags', full_name='pymapadmin.grpc.AppendRequest.flags', index=5, - number=6, type=9, cpp_type=9, label=3, - has_default_value=False, default_value=[], - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='when', full_name='pymapadmin.grpc.AppendRequest.when', index=6, - number=7, type=4, cpp_type=4, label=1, - has_default_value=False, default_value=0, - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - _descriptor.OneofDescriptor( - name='_sender', full_name='pymapadmin.grpc.AppendRequest._sender', - index=0, containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[]), - _descriptor.OneofDescriptor( - name='_recipient', full_name='pymapadmin.grpc.AppendRequest._recipient', - index=1, containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[]), - _descriptor.OneofDescriptor( - name='_mailbox', full_name='pymapadmin.grpc.AppendRequest._mailbox', - index=2, containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[]), - ], - serialized_start=495, - serialized_end=671, -) - - -_APPENDRESPONSE = _descriptor.Descriptor( - name='AppendResponse', - full_name='pymapadmin.grpc.AppendResponse', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - _descriptor.FieldDescriptor( - name='result', full_name='pymapadmin.grpc.AppendResponse.result', index=0, - number=1, type=11, cpp_type=10, label=1, - has_default_value=False, default_value=None, - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='mailbox', full_name='pymapadmin.grpc.AppendResponse.mailbox', index=1, - number=2, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='validity', full_name='pymapadmin.grpc.AppendResponse.validity', index=2, - number=3, type=13, cpp_type=3, label=1, - has_default_value=False, default_value=0, - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='uid', full_name='pymapadmin.grpc.AppendResponse.uid', index=3, - number=4, type=13, cpp_type=3, label=1, - has_default_value=False, default_value=0, - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - _descriptor.OneofDescriptor( - name='_validity', full_name='pymapadmin.grpc.AppendResponse._validity', - index=0, containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[]), - _descriptor.OneofDescriptor( - name='_uid', full_name='pymapadmin.grpc.AppendResponse._uid', - index=1, containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[]), - ], - serialized_start=674, - serialized_end=810, -) - - -_USERDATA_PARAMSENTRY = _descriptor.Descriptor( - name='ParamsEntry', - full_name='pymapadmin.grpc.UserData.ParamsEntry', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - _descriptor.FieldDescriptor( - name='key', full_name='pymapadmin.grpc.UserData.ParamsEntry.key', index=0, - number=1, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='value', full_name='pymapadmin.grpc.UserData.ParamsEntry.value', index=1, - number=2, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=b'8\001', - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - ], - serialized_start=903, - serialized_end=948, -) - -_USERDATA = _descriptor.Descriptor( - name='UserData', - full_name='pymapadmin.grpc.UserData', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - _descriptor.FieldDescriptor( - name='password', full_name='pymapadmin.grpc.UserData.password', index=0, - number=1, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='params', full_name='pymapadmin.grpc.UserData.params', index=1, - number=2, type=11, cpp_type=10, label=3, - has_default_value=False, default_value=[], - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - ], - extensions=[ - ], - nested_types=[_USERDATA_PARAMSENTRY, ], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - _descriptor.OneofDescriptor( - name='_password', full_name='pymapadmin.grpc.UserData._password', - index=0, containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[]), - ], - serialized_start=813, - serialized_end=961, -) - - -_GETUSERREQUEST = _descriptor.Descriptor( - name='GetUserRequest', - full_name='pymapadmin.grpc.GetUserRequest', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - _descriptor.FieldDescriptor( - name='user', full_name='pymapadmin.grpc.GetUserRequest.user', index=0, - number=1, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - ], - serialized_start=963, - serialized_end=993, -) - - -_SETUSERREQUEST = _descriptor.Descriptor( - name='SetUserRequest', - full_name='pymapadmin.grpc.SetUserRequest', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - _descriptor.FieldDescriptor( - name='user', full_name='pymapadmin.grpc.SetUserRequest.user', index=0, - number=1, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='data', full_name='pymapadmin.grpc.SetUserRequest.data', index=1, - number=2, type=11, cpp_type=10, label=1, - has_default_value=False, default_value=None, - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - ], - serialized_start=995, - serialized_end=1066, -) - - -_DELETEUSERREQUEST = _descriptor.Descriptor( - name='DeleteUserRequest', - full_name='pymapadmin.grpc.DeleteUserRequest', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - _descriptor.FieldDescriptor( - name='user', full_name='pymapadmin.grpc.DeleteUserRequest.user', index=0, - number=1, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - ], - serialized_start=1068, - serialized_end=1101, -) - - -_USERRESPONSE = _descriptor.Descriptor( - name='UserResponse', - full_name='pymapadmin.grpc.UserResponse', - filename=None, - file=DESCRIPTOR, - containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[ - _descriptor.FieldDescriptor( - name='result', full_name='pymapadmin.grpc.UserResponse.result', index=0, - number=1, type=11, cpp_type=10, label=1, - has_default_value=False, default_value=None, - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='username', full_name='pymapadmin.grpc.UserResponse.username', index=1, - number=2, type=9, cpp_type=9, label=1, - has_default_value=False, default_value=b"".decode('utf-8'), - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - _descriptor.FieldDescriptor( - name='data', full_name='pymapadmin.grpc.UserResponse.data', index=2, - number=3, type=11, cpp_type=10, label=1, - has_default_value=False, default_value=None, - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - _descriptor.OneofDescriptor( - name='_username', full_name='pymapadmin.grpc.UserResponse._username', - index=0, containing_type=None, - create_key=_descriptor._internal_create_key, - fields=[]), - ], - serialized_start=1104, - serialized_end=1236, -) - -_RESULT.fields_by_name['code'].enum_type = _RESULTCODE -_LOGINREQUEST.oneofs_by_name['_authzid'].fields.append( - _LOGINREQUEST.fields_by_name['authzid']) -_LOGINREQUEST.fields_by_name['authzid'].containing_oneof = _LOGINREQUEST.oneofs_by_name['_authzid'] -_LOGINREQUEST.oneofs_by_name['_token_expiration'].fields.append( - _LOGINREQUEST.fields_by_name['token_expiration']) -_LOGINREQUEST.fields_by_name['token_expiration'].containing_oneof = _LOGINREQUEST.oneofs_by_name['_token_expiration'] -_LOGINRESPONSE.fields_by_name['result'].message_type = _RESULT -_LOGINRESPONSE.oneofs_by_name['_bearer_token'].fields.append( - _LOGINRESPONSE.fields_by_name['bearer_token']) -_LOGINRESPONSE.fields_by_name['bearer_token'].containing_oneof = _LOGINRESPONSE.oneofs_by_name['_bearer_token'] -_PINGRESPONSE.fields_by_name['result'].message_type = _RESULT -_APPENDREQUEST.oneofs_by_name['_sender'].fields.append( - _APPENDREQUEST.fields_by_name['sender']) -_APPENDREQUEST.fields_by_name['sender'].containing_oneof = _APPENDREQUEST.oneofs_by_name['_sender'] -_APPENDREQUEST.oneofs_by_name['_recipient'].fields.append( - _APPENDREQUEST.fields_by_name['recipient']) -_APPENDREQUEST.fields_by_name['recipient'].containing_oneof = _APPENDREQUEST.oneofs_by_name['_recipient'] -_APPENDREQUEST.oneofs_by_name['_mailbox'].fields.append( - _APPENDREQUEST.fields_by_name['mailbox']) -_APPENDREQUEST.fields_by_name['mailbox'].containing_oneof = _APPENDREQUEST.oneofs_by_name['_mailbox'] -_APPENDRESPONSE.fields_by_name['result'].message_type = _RESULT -_APPENDRESPONSE.oneofs_by_name['_validity'].fields.append( - _APPENDRESPONSE.fields_by_name['validity']) -_APPENDRESPONSE.fields_by_name['validity'].containing_oneof = _APPENDRESPONSE.oneofs_by_name['_validity'] -_APPENDRESPONSE.oneofs_by_name['_uid'].fields.append( - _APPENDRESPONSE.fields_by_name['uid']) -_APPENDRESPONSE.fields_by_name['uid'].containing_oneof = _APPENDRESPONSE.oneofs_by_name['_uid'] -_USERDATA_PARAMSENTRY.containing_type = _USERDATA -_USERDATA.fields_by_name['params'].message_type = _USERDATA_PARAMSENTRY -_USERDATA.oneofs_by_name['_password'].fields.append( - _USERDATA.fields_by_name['password']) -_USERDATA.fields_by_name['password'].containing_oneof = _USERDATA.oneofs_by_name['_password'] -_SETUSERREQUEST.fields_by_name['data'].message_type = _USERDATA -_USERRESPONSE.fields_by_name['result'].message_type = _RESULT -_USERRESPONSE.fields_by_name['data'].message_type = _USERDATA -_USERRESPONSE.oneofs_by_name['_username'].fields.append( - _USERRESPONSE.fields_by_name['username']) -_USERRESPONSE.fields_by_name['username'].containing_oneof = _USERRESPONSE.oneofs_by_name['_username'] -DESCRIPTOR.message_types_by_name['Result'] = _RESULT -DESCRIPTOR.message_types_by_name['LoginRequest'] = _LOGINREQUEST -DESCRIPTOR.message_types_by_name['LoginResponse'] = _LOGINRESPONSE -DESCRIPTOR.message_types_by_name['PingRequest'] = _PINGREQUEST -DESCRIPTOR.message_types_by_name['PingResponse'] = _PINGRESPONSE -DESCRIPTOR.message_types_by_name['AppendRequest'] = _APPENDREQUEST -DESCRIPTOR.message_types_by_name['AppendResponse'] = _APPENDRESPONSE -DESCRIPTOR.message_types_by_name['UserData'] = _USERDATA -DESCRIPTOR.message_types_by_name['GetUserRequest'] = _GETUSERREQUEST -DESCRIPTOR.message_types_by_name['SetUserRequest'] = _SETUSERREQUEST -DESCRIPTOR.message_types_by_name['DeleteUserRequest'] = _DELETEUSERREQUEST -DESCRIPTOR.message_types_by_name['UserResponse'] = _USERRESPONSE -DESCRIPTOR.enum_types_by_name['ResultCode'] = _RESULTCODE -_sym_db.RegisterFileDescriptor(DESCRIPTOR) - +_RESULT = DESCRIPTOR.message_types_by_name['Result'] +_LOGINREQUEST = DESCRIPTOR.message_types_by_name['LoginRequest'] +_LOGINRESPONSE = DESCRIPTOR.message_types_by_name['LoginResponse'] +_PINGREQUEST = DESCRIPTOR.message_types_by_name['PingRequest'] +_PINGRESPONSE = DESCRIPTOR.message_types_by_name['PingResponse'] +_APPENDREQUEST = DESCRIPTOR.message_types_by_name['AppendRequest'] +_APPENDRESPONSE = DESCRIPTOR.message_types_by_name['AppendResponse'] +_USERDATA = DESCRIPTOR.message_types_by_name['UserData'] +_USERDATA_PARAMSENTRY = _USERDATA.nested_types_by_name['ParamsEntry'] +_GETUSERREQUEST = DESCRIPTOR.message_types_by_name['GetUserRequest'] +_SETUSERREQUEST = DESCRIPTOR.message_types_by_name['SetUserRequest'] +_DELETEUSERREQUEST = DESCRIPTOR.message_types_by_name['DeleteUserRequest'] +_USERRESPONSE = DESCRIPTOR.message_types_by_name['UserResponse'] Result = _reflection.GeneratedProtocolMessageType('Result', (_message.Message,), { 'DESCRIPTOR' : _RESULT, '__module__' : 'pymapadmin.grpc.admin_pb2' @@ -811,114 +128,46 @@ }) _sym_db.RegisterMessage(UserResponse) - -_USERDATA_PARAMSENTRY._options = None - -_SYSTEM = _descriptor.ServiceDescriptor( - name='System', - full_name='pymapadmin.grpc.System', - file=DESCRIPTOR, - index=0, - serialized_options=None, - create_key=_descriptor._internal_create_key, - serialized_start=1279, - serialized_end=1432, - methods=[ - _descriptor.MethodDescriptor( - name='Ping', - full_name='pymapadmin.grpc.System.Ping', - index=0, - containing_service=None, - input_type=_PINGREQUEST, - output_type=_PINGRESPONSE, - serialized_options=None, - create_key=_descriptor._internal_create_key, - ), - _descriptor.MethodDescriptor( - name='Login', - full_name='pymapadmin.grpc.System.Login', - index=1, - containing_service=None, - input_type=_LOGINREQUEST, - output_type=_LOGINRESPONSE, - serialized_options=None, - create_key=_descriptor._internal_create_key, - ), -]) -_sym_db.RegisterServiceDescriptor(_SYSTEM) - -DESCRIPTOR.services_by_name['System'] = _SYSTEM - - -_MAILBOX = _descriptor.ServiceDescriptor( - name='Mailbox', - full_name='pymapadmin.grpc.Mailbox', - file=DESCRIPTOR, - index=1, - serialized_options=None, - create_key=_descriptor._internal_create_key, - serialized_start=1434, - serialized_end=1520, - methods=[ - _descriptor.MethodDescriptor( - name='Append', - full_name='pymapadmin.grpc.Mailbox.Append', - index=0, - containing_service=None, - input_type=_APPENDREQUEST, - output_type=_APPENDRESPONSE, - serialized_options=None, - create_key=_descriptor._internal_create_key, - ), -]) -_sym_db.RegisterServiceDescriptor(_MAILBOX) - -DESCRIPTOR.services_by_name['Mailbox'] = _MAILBOX - - -_USER = _descriptor.ServiceDescriptor( - name='User', - full_name='pymapadmin.grpc.User', - file=DESCRIPTOR, - index=2, - serialized_options=None, - create_key=_descriptor._internal_create_key, - serialized_start=1523, - serialized_end=1766, - methods=[ - _descriptor.MethodDescriptor( - name='GetUser', - full_name='pymapadmin.grpc.User.GetUser', - index=0, - containing_service=None, - input_type=_GETUSERREQUEST, - output_type=_USERRESPONSE, - serialized_options=None, - create_key=_descriptor._internal_create_key, - ), - _descriptor.MethodDescriptor( - name='SetUser', - full_name='pymapadmin.grpc.User.SetUser', - index=1, - containing_service=None, - input_type=_SETUSERREQUEST, - output_type=_USERRESPONSE, - serialized_options=None, - create_key=_descriptor._internal_create_key, - ), - _descriptor.MethodDescriptor( - name='DeleteUser', - full_name='pymapadmin.grpc.User.DeleteUser', - index=2, - containing_service=None, - input_type=_DELETEUSERREQUEST, - output_type=_USERRESPONSE, - serialized_options=None, - create_key=_descriptor._internal_create_key, - ), -]) -_sym_db.RegisterServiceDescriptor(_USER) - -DESCRIPTOR.services_by_name['User'] = _USER - +_SYSTEM = DESCRIPTOR.services_by_name['System'] +_MAILBOX = DESCRIPTOR.services_by_name['Mailbox'] +_USER = DESCRIPTOR.services_by_name['User'] +if _descriptor._USE_C_DESCRIPTORS == False: + + DESCRIPTOR._options = None + _USERDATA_PARAMSENTRY._options = None + _USERDATA_PARAMSENTRY._serialized_options = b'8\001' + _RESULTCODE._serialized_start=1238 + _RESULTCODE._serialized_end=1276 + _RESULT._serialized_start=48 + _RESULT._serialized_end=130 + _LOGINREQUEST._serialized_start=133 + _LOGINREQUEST._serialized_end=266 + _LOGINRESPONSE._serialized_start=268 + _LOGINRESPONSE._serialized_end=368 + _PINGREQUEST._serialized_start=370 + _PINGREQUEST._serialized_end=383 + _PINGRESPONSE._serialized_start=385 + _PINGRESPONSE._serialized_end=492 + _APPENDREQUEST._serialized_start=495 + _APPENDREQUEST._serialized_end=671 + _APPENDRESPONSE._serialized_start=674 + _APPENDRESPONSE._serialized_end=810 + _USERDATA._serialized_start=813 + _USERDATA._serialized_end=961 + _USERDATA_PARAMSENTRY._serialized_start=903 + _USERDATA_PARAMSENTRY._serialized_end=948 + _GETUSERREQUEST._serialized_start=963 + _GETUSERREQUEST._serialized_end=993 + _SETUSERREQUEST._serialized_start=995 + _SETUSERREQUEST._serialized_end=1066 + _DELETEUSERREQUEST._serialized_start=1068 + _DELETEUSERREQUEST._serialized_end=1101 + _USERRESPONSE._serialized_start=1104 + _USERRESPONSE._serialized_end=1236 + _SYSTEM._serialized_start=1279 + _SYSTEM._serialized_end=1432 + _MAILBOX._serialized_start=1434 + _MAILBOX._serialized_end=1520 + _USER._serialized_start=1523 + _USER._serialized_end=1766 # @@protoc_insertion_point(module_scope) diff --git a/pymapadmin/grpc/admin_pb2.pyi b/pymapadmin/grpc/admin_pb2.pyi index 8634227..1d2d8ee 100644 --- a/pymapadmin/grpc/admin_pb2.pyi +++ b/pymapadmin/grpc/admin_pb2.pyi @@ -3,116 +3,138 @@ isort:skip_file """ import builtins +import collections.abc import google.protobuf.descriptor import google.protobuf.internal.containers import google.protobuf.internal.enum_type_wrapper import google.protobuf.message +import sys import typing -import typing_extensions -DESCRIPTOR: google.protobuf.descriptor.FileDescriptor = ... +if sys.version_info >= (3, 10): + import typing as typing_extensions +else: + import typing_extensions + +DESCRIPTOR: google.protobuf.descriptor.FileDescriptor class _ResultCode: - ValueType = typing.NewType('ValueType', builtins.int) - V = typing.Union[ValueType] -class _ResultCodeEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_ResultCode.ValueType], builtins.type): - DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor = ... - SUCCESS: ResultCode.ValueType = ... # 0 - FAILURE: ResultCode.ValueType = ... # 1 -class ResultCode(_ResultCode, metaclass=_ResultCodeEnumTypeWrapper): - pass - -SUCCESS: ResultCode.ValueType = ... # 0 -FAILURE: ResultCode.ValueType = ... # 1 -global___ResultCode = ResultCode + ValueType = typing.NewType("ValueType", builtins.int) + V: typing_extensions.TypeAlias = ValueType + +class _ResultCodeEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_ResultCode.ValueType], builtins.type): # noqa: F821 + DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor + SUCCESS: _ResultCode.ValueType # 0 + FAILURE: _ResultCode.ValueType # 1 +class ResultCode(_ResultCode, metaclass=_ResultCodeEnumTypeWrapper): ... + +SUCCESS: ResultCode.ValueType # 0 +FAILURE: ResultCode.ValueType # 1 +global___ResultCode = ResultCode class Result(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + CODE_FIELD_NUMBER: builtins.int RESPONSE_FIELD_NUMBER: builtins.int KEY_FIELD_NUMBER: builtins.int - code: global___ResultCode.ValueType = ... - response: builtins.bytes = ... - key: typing.Text = ... - def __init__(self, + code: global___ResultCode.ValueType + response: builtins.bytes + key: builtins.str + def __init__( + self, *, - code : global___ResultCode.ValueType = ..., - response : builtins.bytes = ..., - key : typing.Text = ..., - ) -> None: ... - def ClearField(self, field_name: typing_extensions.Literal["code",b"code","key",b"key","response",b"response"]) -> None: ... + code: global___ResultCode.ValueType = ..., + response: builtins.bytes = ..., + key: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["code", b"code", "key", b"key", "response", b"response"]) -> None: ... + global___Result = Result class LoginRequest(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + AUTHCID_FIELD_NUMBER: builtins.int SECRET_FIELD_NUMBER: builtins.int AUTHZID_FIELD_NUMBER: builtins.int TOKEN_EXPIRATION_FIELD_NUMBER: builtins.int - authcid: typing.Text = ... - secret: typing.Text = ... - authzid: typing.Text = ... - token_expiration: builtins.float = ... - def __init__(self, + authcid: builtins.str + secret: builtins.str + authzid: builtins.str + token_expiration: builtins.float + def __init__( + self, *, - authcid : typing.Text = ..., - secret : typing.Text = ..., - authzid : typing.Optional[typing.Text] = ..., - token_expiration : typing.Optional[builtins.float] = ..., - ) -> None: ... - def HasField(self, field_name: typing_extensions.Literal["_authzid",b"_authzid","_token_expiration",b"_token_expiration","authzid",b"authzid","token_expiration",b"token_expiration"]) -> builtins.bool: ... - def ClearField(self, field_name: typing_extensions.Literal["_authzid",b"_authzid","_token_expiration",b"_token_expiration","authcid",b"authcid","authzid",b"authzid","secret",b"secret","token_expiration",b"token_expiration"]) -> None: ... + authcid: builtins.str = ..., + secret: builtins.str = ..., + authzid: builtins.str | None = ..., + token_expiration: builtins.float | None = ..., + ) -> None: ... + def HasField(self, field_name: typing_extensions.Literal["_authzid", b"_authzid", "_token_expiration", b"_token_expiration", "authzid", b"authzid", "token_expiration", b"token_expiration"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["_authzid", b"_authzid", "_token_expiration", b"_token_expiration", "authcid", b"authcid", "authzid", b"authzid", "secret", b"secret", "token_expiration", b"token_expiration"]) -> None: ... @typing.overload - def WhichOneof(self, oneof_group: typing_extensions.Literal["_authzid",b"_authzid"]) -> typing.Optional[typing_extensions.Literal["authzid"]]: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["_authzid", b"_authzid"]) -> typing_extensions.Literal["authzid"] | None: ... @typing.overload - def WhichOneof(self, oneof_group: typing_extensions.Literal["_token_expiration",b"_token_expiration"]) -> typing.Optional[typing_extensions.Literal["token_expiration"]]: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["_token_expiration", b"_token_expiration"]) -> typing_extensions.Literal["token_expiration"] | None: ... + global___LoginRequest = LoginRequest class LoginResponse(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + RESULT_FIELD_NUMBER: builtins.int BEARER_TOKEN_FIELD_NUMBER: builtins.int @property def result(self) -> global___Result: ... - bearer_token: typing.Text = ... - def __init__(self, + bearer_token: builtins.str + def __init__( + self, *, - result : typing.Optional[global___Result] = ..., - bearer_token : typing.Optional[typing.Text] = ..., - ) -> None: ... - def HasField(self, field_name: typing_extensions.Literal["_bearer_token",b"_bearer_token","bearer_token",b"bearer_token","result",b"result"]) -> builtins.bool: ... - def ClearField(self, field_name: typing_extensions.Literal["_bearer_token",b"_bearer_token","bearer_token",b"bearer_token","result",b"result"]) -> None: ... - def WhichOneof(self, oneof_group: typing_extensions.Literal["_bearer_token",b"_bearer_token"]) -> typing.Optional[typing_extensions.Literal["bearer_token"]]: ... + result: global___Result | None = ..., + bearer_token: builtins.str | None = ..., + ) -> None: ... + def HasField(self, field_name: typing_extensions.Literal["_bearer_token", b"_bearer_token", "bearer_token", b"bearer_token", "result", b"result"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["_bearer_token", b"_bearer_token", "bearer_token", b"bearer_token", "result", b"result"]) -> None: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["_bearer_token", b"_bearer_token"]) -> typing_extensions.Literal["bearer_token"] | None: ... + global___LoginResponse = LoginResponse class PingRequest(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... - def __init__(self, - ) -> None: ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + def __init__( + self, + ) -> None: ... + global___PingRequest = PingRequest class PingResponse(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + RESULT_FIELD_NUMBER: builtins.int PYMAP_VERSION_FIELD_NUMBER: builtins.int PYMAP_ADMIN_VERSION_FIELD_NUMBER: builtins.int @property def result(self) -> global___Result: ... - pymap_version: typing.Text = ... - pymap_admin_version: typing.Text = ... - def __init__(self, + pymap_version: builtins.str + pymap_admin_version: builtins.str + def __init__( + self, *, - result : typing.Optional[global___Result] = ..., - pymap_version : typing.Text = ..., - pymap_admin_version : typing.Text = ..., - ) -> None: ... - def HasField(self, field_name: typing_extensions.Literal["result",b"result"]) -> builtins.bool: ... - def ClearField(self, field_name: typing_extensions.Literal["pymap_admin_version",b"pymap_admin_version","pymap_version",b"pymap_version","result",b"result"]) -> None: ... + result: global___Result | None = ..., + pymap_version: builtins.str = ..., + pymap_admin_version: builtins.str = ..., + ) -> None: ... + def HasField(self, field_name: typing_extensions.Literal["result", b"result"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["pymap_admin_version", b"pymap_admin_version", "pymap_version", b"pymap_version", "result", b"result"]) -> None: ... + global___PingResponse = PingResponse class AppendRequest(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + USER_FIELD_NUMBER: builtins.int SENDER_FIELD_NUMBER: builtins.int RECIPIENT_FIELD_NUMBER: builtins.int @@ -120,145 +142,167 @@ class AppendRequest(google.protobuf.message.Message): DATA_FIELD_NUMBER: builtins.int FLAGS_FIELD_NUMBER: builtins.int WHEN_FIELD_NUMBER: builtins.int - user: typing.Text = ... - sender: typing.Text = ... - recipient: typing.Text = ... - mailbox: typing.Text = ... - data: builtins.bytes = ... + user: builtins.str + sender: builtins.str + recipient: builtins.str + mailbox: builtins.str + data: builtins.bytes @property - def flags(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[typing.Text]: ... - when: builtins.int = ... - def __init__(self, + def flags(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]: ... + when: builtins.int + def __init__( + self, *, - user : typing.Text = ..., - sender : typing.Optional[typing.Text] = ..., - recipient : typing.Optional[typing.Text] = ..., - mailbox : typing.Optional[typing.Text] = ..., - data : builtins.bytes = ..., - flags : typing.Optional[typing.Iterable[typing.Text]] = ..., - when : builtins.int = ..., - ) -> None: ... - def HasField(self, field_name: typing_extensions.Literal["_mailbox",b"_mailbox","_recipient",b"_recipient","_sender",b"_sender","mailbox",b"mailbox","recipient",b"recipient","sender",b"sender"]) -> builtins.bool: ... - def ClearField(self, field_name: typing_extensions.Literal["_mailbox",b"_mailbox","_recipient",b"_recipient","_sender",b"_sender","data",b"data","flags",b"flags","mailbox",b"mailbox","recipient",b"recipient","sender",b"sender","user",b"user","when",b"when"]) -> None: ... + user: builtins.str = ..., + sender: builtins.str | None = ..., + recipient: builtins.str | None = ..., + mailbox: builtins.str | None = ..., + data: builtins.bytes = ..., + flags: collections.abc.Iterable[builtins.str] | None = ..., + when: builtins.int = ..., + ) -> None: ... + def HasField(self, field_name: typing_extensions.Literal["_mailbox", b"_mailbox", "_recipient", b"_recipient", "_sender", b"_sender", "mailbox", b"mailbox", "recipient", b"recipient", "sender", b"sender"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["_mailbox", b"_mailbox", "_recipient", b"_recipient", "_sender", b"_sender", "data", b"data", "flags", b"flags", "mailbox", b"mailbox", "recipient", b"recipient", "sender", b"sender", "user", b"user", "when", b"when"]) -> None: ... @typing.overload - def WhichOneof(self, oneof_group: typing_extensions.Literal["_mailbox",b"_mailbox"]) -> typing.Optional[typing_extensions.Literal["mailbox"]]: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["_mailbox", b"_mailbox"]) -> typing_extensions.Literal["mailbox"] | None: ... @typing.overload - def WhichOneof(self, oneof_group: typing_extensions.Literal["_recipient",b"_recipient"]) -> typing.Optional[typing_extensions.Literal["recipient"]]: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["_recipient", b"_recipient"]) -> typing_extensions.Literal["recipient"] | None: ... @typing.overload - def WhichOneof(self, oneof_group: typing_extensions.Literal["_sender",b"_sender"]) -> typing.Optional[typing_extensions.Literal["sender"]]: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["_sender", b"_sender"]) -> typing_extensions.Literal["sender"] | None: ... + global___AppendRequest = AppendRequest class AppendResponse(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + RESULT_FIELD_NUMBER: builtins.int MAILBOX_FIELD_NUMBER: builtins.int VALIDITY_FIELD_NUMBER: builtins.int UID_FIELD_NUMBER: builtins.int @property def result(self) -> global___Result: ... - mailbox: typing.Text = ... - validity: builtins.int = ... - uid: builtins.int = ... - def __init__(self, + mailbox: builtins.str + validity: builtins.int + uid: builtins.int + def __init__( + self, *, - result : typing.Optional[global___Result] = ..., - mailbox : typing.Text = ..., - validity : typing.Optional[builtins.int] = ..., - uid : typing.Optional[builtins.int] = ..., - ) -> None: ... - def HasField(self, field_name: typing_extensions.Literal["_uid",b"_uid","_validity",b"_validity","result",b"result","uid",b"uid","validity",b"validity"]) -> builtins.bool: ... - def ClearField(self, field_name: typing_extensions.Literal["_uid",b"_uid","_validity",b"_validity","mailbox",b"mailbox","result",b"result","uid",b"uid","validity",b"validity"]) -> None: ... + result: global___Result | None = ..., + mailbox: builtins.str = ..., + validity: builtins.int | None = ..., + uid: builtins.int | None = ..., + ) -> None: ... + def HasField(self, field_name: typing_extensions.Literal["_uid", b"_uid", "_validity", b"_validity", "result", b"result", "uid", b"uid", "validity", b"validity"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["_uid", b"_uid", "_validity", b"_validity", "mailbox", b"mailbox", "result", b"result", "uid", b"uid", "validity", b"validity"]) -> None: ... @typing.overload - def WhichOneof(self, oneof_group: typing_extensions.Literal["_uid",b"_uid"]) -> typing.Optional[typing_extensions.Literal["uid"]]: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["_uid", b"_uid"]) -> typing_extensions.Literal["uid"] | None: ... @typing.overload - def WhichOneof(self, oneof_group: typing_extensions.Literal["_validity",b"_validity"]) -> typing.Optional[typing_extensions.Literal["validity"]]: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["_validity", b"_validity"]) -> typing_extensions.Literal["validity"] | None: ... + global___AppendResponse = AppendResponse class UserData(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + class ParamsEntry(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + KEY_FIELD_NUMBER: builtins.int VALUE_FIELD_NUMBER: builtins.int - key: typing.Text = ... - value: typing.Text = ... - def __init__(self, + key: builtins.str + value: builtins.str + def __init__( + self, *, - key : typing.Text = ..., - value : typing.Text = ..., - ) -> None: ... - def ClearField(self, field_name: typing_extensions.Literal["key",b"key","value",b"value"]) -> None: ... + key: builtins.str = ..., + value: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["key", b"key", "value", b"value"]) -> None: ... PASSWORD_FIELD_NUMBER: builtins.int PARAMS_FIELD_NUMBER: builtins.int - password: typing.Text = ... + password: builtins.str @property - def params(self) -> google.protobuf.internal.containers.ScalarMap[typing.Text, typing.Text]: ... - def __init__(self, + def params(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]: ... + def __init__( + self, *, - password : typing.Optional[typing.Text] = ..., - params : typing.Optional[typing.Mapping[typing.Text, typing.Text]] = ..., - ) -> None: ... - def HasField(self, field_name: typing_extensions.Literal["_password",b"_password","password",b"password"]) -> builtins.bool: ... - def ClearField(self, field_name: typing_extensions.Literal["_password",b"_password","params",b"params","password",b"password"]) -> None: ... - def WhichOneof(self, oneof_group: typing_extensions.Literal["_password",b"_password"]) -> typing.Optional[typing_extensions.Literal["password"]]: ... + password: builtins.str | None = ..., + params: collections.abc.Mapping[builtins.str, builtins.str] | None = ..., + ) -> None: ... + def HasField(self, field_name: typing_extensions.Literal["_password", b"_password", "password", b"password"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["_password", b"_password", "params", b"params", "password", b"password"]) -> None: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["_password", b"_password"]) -> typing_extensions.Literal["password"] | None: ... + global___UserData = UserData class GetUserRequest(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + USER_FIELD_NUMBER: builtins.int - user: typing.Text = ... - def __init__(self, + user: builtins.str + def __init__( + self, *, - user : typing.Text = ..., - ) -> None: ... - def ClearField(self, field_name: typing_extensions.Literal["user",b"user"]) -> None: ... + user: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["user", b"user"]) -> None: ... + global___GetUserRequest = GetUserRequest class SetUserRequest(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + USER_FIELD_NUMBER: builtins.int DATA_FIELD_NUMBER: builtins.int - user: typing.Text = ... + user: builtins.str @property def data(self) -> global___UserData: ... - def __init__(self, + def __init__( + self, *, - user : typing.Text = ..., - data : typing.Optional[global___UserData] = ..., - ) -> None: ... - def HasField(self, field_name: typing_extensions.Literal["data",b"data"]) -> builtins.bool: ... - def ClearField(self, field_name: typing_extensions.Literal["data",b"data","user",b"user"]) -> None: ... + user: builtins.str = ..., + data: global___UserData | None = ..., + ) -> None: ... + def HasField(self, field_name: typing_extensions.Literal["data", b"data"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["data", b"data", "user", b"user"]) -> None: ... + global___SetUserRequest = SetUserRequest class DeleteUserRequest(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + USER_FIELD_NUMBER: builtins.int - user: typing.Text = ... - def __init__(self, + user: builtins.str + def __init__( + self, *, - user : typing.Text = ..., - ) -> None: ... - def ClearField(self, field_name: typing_extensions.Literal["user",b"user"]) -> None: ... + user: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing_extensions.Literal["user", b"user"]) -> None: ... + global___DeleteUserRequest = DeleteUserRequest class UserResponse(google.protobuf.message.Message): - DESCRIPTOR: google.protobuf.descriptor.Descriptor = ... + DESCRIPTOR: google.protobuf.descriptor.Descriptor + RESULT_FIELD_NUMBER: builtins.int USERNAME_FIELD_NUMBER: builtins.int DATA_FIELD_NUMBER: builtins.int @property def result(self) -> global___Result: ... - username: typing.Text = ... + username: builtins.str @property def data(self) -> global___UserData: ... - def __init__(self, + def __init__( + self, *, - result : typing.Optional[global___Result] = ..., - username : typing.Optional[typing.Text] = ..., - data : typing.Optional[global___UserData] = ..., - ) -> None: ... - def HasField(self, field_name: typing_extensions.Literal["_username",b"_username","data",b"data","result",b"result","username",b"username"]) -> builtins.bool: ... - def ClearField(self, field_name: typing_extensions.Literal["_username",b"_username","data",b"data","result",b"result","username",b"username"]) -> None: ... - def WhichOneof(self, oneof_group: typing_extensions.Literal["_username",b"_username"]) -> typing.Optional[typing_extensions.Literal["username"]]: ... + result: global___Result | None = ..., + username: builtins.str | None = ..., + data: global___UserData | None = ..., + ) -> None: ... + def HasField(self, field_name: typing_extensions.Literal["_username", b"_username", "data", b"data", "result", b"result", "username", b"username"]) -> builtins.bool: ... + def ClearField(self, field_name: typing_extensions.Literal["_username", b"_username", "data", b"data", "result", b"result", "username", b"username"]) -> None: ... + def WhichOneof(self, oneof_group: typing_extensions.Literal["_username", b"_username"]) -> typing_extensions.Literal["username"] | None: ... + global___UserResponse = UserResponse diff --git a/setup.py b/setup.py index 7f4601f..ba30cf0 100644 --- a/setup.py +++ b/setup.py @@ -19,7 +19,7 @@ # THE SOFTWARE. # -from setuptools import setup, find_packages # type: ignore +from setuptools import setup, find_packages with open('README.md') as f: readme = f.read() @@ -29,7 +29,7 @@ setup(name='pymap-admin', - version='0.8.0', + version='0.9.0', author='Ian Good', author_email='ian@icgood.net', description='Admin tool for running pymap instances.', @@ -50,7 +50,9 @@ include_package_data=True, packages=find_packages(include=('pymapadmin', 'pymapadmin.*')), install_requires=[ - 'grpclib', 'protobuf', 'typing-extensions'], + 'grpclib', + 'protobuf', + 'typing-extensions'], extras_require={ 'optional': ['googleapis-common-protos'], 'build': ['grpcio-tools', 'mypy-protobuf']},