lightning-sdk 2025.12.16__py3-none-any.whl → 2026.1.22__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- lightning_sdk/__version__.py +1 -1
- lightning_sdk/api/k8s_api.py +75 -29
- lightning_sdk/api/org_api.py +7 -0
- lightning_sdk/api/studio_api.py +223 -36
- lightning_sdk/api/teamspace_api.py +28 -9
- lightning_sdk/api/user_api.py +5 -0
- lightning_sdk/cli/cp/__init__.py +64 -0
- lightning_sdk/cli/entrypoint.py +2 -0
- lightning_sdk/cli/groups.py +22 -0
- lightning_sdk/cli/legacy/clusters_menu.py +2 -2
- lightning_sdk/cli/legacy/deploy/_auth.py +7 -6
- lightning_sdk/cli/legacy/download.py +2 -1
- lightning_sdk/cli/legacy/run.py +13 -2
- lightning_sdk/cli/legacy/studios_menu.py +8 -1
- lightning_sdk/cli/studio/__init__.py +4 -0
- lightning_sdk/cli/studio/cp.py +20 -64
- lightning_sdk/cli/studio/ls.py +57 -0
- lightning_sdk/cli/studio/rm.py +71 -0
- lightning_sdk/cli/utils/logging.py +2 -1
- lightning_sdk/cli/utils/studio_filesystem.py +65 -0
- lightning_sdk/cli/utils/teamspace_selection.py +5 -0
- lightning_sdk/exceptions.py +4 -0
- lightning_sdk/job/base.py +24 -5
- lightning_sdk/job/job.py +12 -5
- lightning_sdk/job/v1.py +5 -2
- lightning_sdk/job/v2.py +9 -1
- lightning_sdk/k8s_cluster.py +9 -10
- lightning_sdk/lightning_cloud/__version__.py +1 -1
- lightning_sdk/lightning_cloud/openapi/__init__.py +46 -3
- lightning_sdk/lightning_cloud/openapi/api/__init__.py +1 -0
- lightning_sdk/lightning_cloud/openapi/api/cloud_space_service_api.py +118 -1
- lightning_sdk/lightning_cloud/openapi/api/cluster_service_api.py +787 -125
- lightning_sdk/lightning_cloud/openapi/api/data_connection_service_api.py +5 -1
- lightning_sdk/lightning_cloud/openapi/api/file_system_service_api.py +11 -11
- lightning_sdk/lightning_cloud/openapi/api/k8_s_cluster_service_api.py +246 -19
- lightning_sdk/lightning_cloud/openapi/api/lightningwork_service_api.py +116 -11
- lightning_sdk/lightning_cloud/openapi/api/lit_logger_service_api.py +588 -2
- lightning_sdk/lightning_cloud/openapi/api/models_store_api.py +9 -1
- lightning_sdk/lightning_cloud/openapi/api/storage_service_api.py +5 -1
- lightning_sdk/lightning_cloud/openapi/api/virtual_machine_service_api.py +557 -0
- lightning_sdk/lightning_cloud/openapi/models/__init__.py +45 -3
- lightning_sdk/lightning_cloud/openapi/models/cloud_space_environment_template_service_update_cloud_space_environment_template_body.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/cluster_service_add_container_registry_body.py +123 -0
- lightning_sdk/lightning_cloud/openapi/models/cluster_service_create_cluster_capacity_reservation_body.py +53 -1
- lightning_sdk/lightning_cloud/openapi/models/cluster_service_create_machine_body.py +79 -1
- lightning_sdk/lightning_cloud/openapi/models/cluster_service_create_org_cluster_capacity_reservation_body.py +409 -0
- lightning_sdk/lightning_cloud/openapi/models/cluster_service_refresh_container_registry_credentials_body.py +97 -0
- lightning_sdk/lightning_cloud/openapi/models/cluster_service_report_machine_system_metrics_body.py +123 -0
- lightning_sdk/lightning_cloud/openapi/models/cluster_service_validate_container_registry_body.py +97 -0
- lightning_sdk/lightning_cloud/openapi/models/externalv1_cloud_space_instance_status.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/lit_logger_service_create_lit_logger_media_body.py +305 -0
- lightning_sdk/lightning_cloud/openapi/models/lit_logger_service_update_lit_logger_media_body.py +149 -0
- lightning_sdk/lightning_cloud/openapi/models/lit_logger_service_update_metrics_stream_body.py +53 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_add_container_registry_response.py +123 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_capacity_reservation_used_by.py +227 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_cloud_provider.py +1 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_cloud_space_environment_template_config.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_cloud_space_environment_type.py +1 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_cloud_space_specialized_view.py +1 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_cluster_accelerator.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_cluster_capacity_reservation.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_cluster_spec.py +53 -27
- lightning_sdk/lightning_cloud/openapi/models/v1_cluster_type.py +0 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_container_registry.py +253 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_container_registry_info.py +281 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_container_registry_integration.py +123 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_container_registry_status.py +105 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_create_cloud_space_environment_template_request.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_create_lit_logger_media_response.py +149 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_create_org_cluster_capacity_reservation_response.py +201 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_create_sdk_command_history_request.py +29 -3
- lightning_sdk/lightning_cloud/openapi/models/v1_cudo_direct_v1.py +175 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_delete_container_registry_response.py +97 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_delete_lit_logger_media_response.py +97 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_delete_virtual_machine_response.py +97 -0
- lightning_sdk/lightning_cloud/openapi/models/{v1_ai_pod_v1.py → v1_ecr_registry_config.py} +49 -49
- lightning_sdk/lightning_cloud/openapi/models/v1_ecr_registry_config_input.py +123 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_ecr_registry_details.py +201 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_external_cluster_spec.py +27 -27
- lightning_sdk/lightning_cloud/openapi/models/v1_external_search_user.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_get_artifacts_page_response.py +29 -3
- lightning_sdk/lightning_cloud/openapi/models/v1_get_kubernetes_pod_logs_response.py +149 -0
- lightning_sdk/lightning_cloud/openapi/models/{v1_get_machine_response.py → v1_get_kubernetes_pod_response.py} +23 -23
- lightning_sdk/lightning_cloud/openapi/models/v1_get_user_response.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_job_spec.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_joinable_organization.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_k8s_incident_setting.py +149 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_k8s_incident_type.py +108 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_kubernetes_direct_settings_v1.py +53 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_kubernetes_direct_v1.py +105 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_kubernetes_pod.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_kubernetes_pod_logs_page.py +227 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_kubevirt_config.py +357 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_list_container_registries_response.py +123 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_list_kubernetes_pods_response.py +43 -17
- lightning_sdk/lightning_cloud/openapi/models/v1_list_kubernetes_pods_sort_order.py +104 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_list_lit_logger_media_response.py +149 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_list_models_response.py +55 -3
- lightning_sdk/lightning_cloud/openapi/models/v1_list_virtual_machines_response.py +123 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_lit_logger_media.py +513 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_machine.py +53 -53
- lightning_sdk/lightning_cloud/openapi/models/v1_machine_direct_v1.py +107 -3
- lightning_sdk/lightning_cloud/openapi/models/v1_media_type.py +104 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_nebius_direct_v1.py +29 -3
- lightning_sdk/lightning_cloud/openapi/models/v1_node_metrics.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_organization.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_refresh_container_registry_credentials_response.py +123 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_report_cloud_space_instance_idle_state_response.py +97 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_report_machine_system_metrics_response.py +97 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_search_user.py +27 -1
- lightning_sdk/lightning_cloud/openapi/models/v1_tenant_credentials.py +201 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_user_features.py +217 -113
- lightning_sdk/lightning_cloud/openapi/models/v1_validate_container_registry_response.py +149 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_virtual_machine.py +409 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_vm_configuration.py +149 -0
- lightning_sdk/lightning_cloud/openapi/models/v1_vm_provider_configuration.py +227 -0
- lightning_sdk/lightning_cloud/openapi/models/virtual_machine_service_create_virtual_machine_body.py +565 -0
- lightning_sdk/lightning_cloud/openapi/models/virtual_machine_service_update_virtual_machine_body.py +97 -0
- lightning_sdk/lightning_cloud/openapi/rest.py +2 -2
- lightning_sdk/lightning_cloud/rest_client.py +0 -2
- lightning_sdk/machine.py +3 -3
- lightning_sdk/mmt/base.py +26 -7
- lightning_sdk/mmt/mmt.py +11 -6
- lightning_sdk/mmt/v1.py +5 -2
- lightning_sdk/mmt/v2.py +5 -2
- lightning_sdk/organization.py +10 -1
- lightning_sdk/owner.py +4 -0
- lightning_sdk/plugin.py +2 -2
- lightning_sdk/studio.py +47 -6
- lightning_sdk/user.py +22 -2
- lightning_sdk/utils/logging.py +2 -1
- lightning_sdk/utils/resolve.py +9 -7
- {lightning_sdk-2025.12.16.dist-info → lightning_sdk-2026.1.22.dist-info}/METADATA +1 -5
- {lightning_sdk-2025.12.16.dist-info → lightning_sdk-2026.1.22.dist-info}/RECORD +139 -94
- {lightning_sdk-2025.12.16.dist-info → lightning_sdk-2026.1.22.dist-info}/WHEEL +1 -1
- lightning_sdk/lightning_cloud/cli/__main__.py +0 -29
- lightning_sdk/lightning_cloud/source_code/logs_socket_api.py +0 -103
- /lightning_sdk/lightning_cloud/openapi/models/{v1_list_filesystem_mm_ts_response.py → v1_list_filesystem_mmts_response.py} +0 -0
- {lightning_sdk-2025.12.16.dist-info → lightning_sdk-2026.1.22.dist-info}/LICENSE +0 -0
- {lightning_sdk-2025.12.16.dist-info → lightning_sdk-2026.1.22.dist-info}/entry_points.txt +0 -0
- {lightning_sdk-2025.12.16.dist-info → lightning_sdk-2026.1.22.dist-info}/top_level.txt +0 -0
|
@@ -73,6 +73,7 @@ class V1ClusterAccelerator(object):
|
|
|
73
73
|
'max_available_quota': 'str',
|
|
74
74
|
'non_spot': 'bool',
|
|
75
75
|
'out_of_capacity': 'bool',
|
|
76
|
+
'partitionable_parent': 'str',
|
|
76
77
|
'persistent_disk_supported': 'bool',
|
|
77
78
|
'provider': 'V1CloudProvider',
|
|
78
79
|
'quota_checked_at': 'datetime',
|
|
@@ -130,6 +131,7 @@ class V1ClusterAccelerator(object):
|
|
|
130
131
|
'max_available_quota': 'maxAvailableQuota',
|
|
131
132
|
'non_spot': 'nonSpot',
|
|
132
133
|
'out_of_capacity': 'outOfCapacity',
|
|
134
|
+
'partitionable_parent': 'partitionableParent',
|
|
133
135
|
'persistent_disk_supported': 'persistentDiskSupported',
|
|
134
136
|
'provider': 'provider',
|
|
135
137
|
'quota_checked_at': 'quotaCheckedAt',
|
|
@@ -154,7 +156,7 @@ class V1ClusterAccelerator(object):
|
|
|
154
156
|
'spot_quota_page_url': 'spotQuotaPageUrl'
|
|
155
157
|
}
|
|
156
158
|
|
|
157
|
-
def __init__(self, accelerator_type: 'str' =None, allowed_resources: 'list[str]' =None, availability_strategy: 'str' =None, available_in_seconds: 'str' =None, available_in_seconds_spot: 'str' =None, available_zones: 'list[str]' =None, byoc_only: 'bool' =None, capacity_block_only: 'bool' =None, capacity_block_price: 'float' =None, capacity_blocks_available: 'list[V1ClusterCapacityReservation]' =None, cluster_id: 'str' =None, cost: 'float' =None, detailed_quotas_info: 'list[V1AcceleratorQuotaInfo]' =None, device_card: 'str' =None, device_info: 'str' =None, display_name: 'str' =None, dws_cost: 'float' =None, dws_only: 'bool' =None, dws_supported: 'bool' =None, enabled: 'bool' =None, family: 'str' =None, instance_id: 'str' =None, is_custom: 'bool' =None, is_tier_restricted: 'bool' =None, lightning_interruptible: 'bool' =None, local_disk_included: 'bool' =None, local_disk_size: 'str' =None, local_disk_supported: 'bool' =None, local_disks_count: 'str' =None, max_available_quota: 'str' =None, non_spot: 'bool' =None, out_of_capacity: 'bool' =None, persistent_disk_supported: 'bool' =None, provider: 'V1CloudProvider' =None, quota_checked_at: 'datetime' =None, quota_code: 'str' =None, quota_name: 'str' =None, quota_page_url: 'str' =None, quota_service_code: 'str' =None, quota_utilization: 'str' =None, quota_value: 'str' =None, reservable: 'bool' =None, reservation_available_zones: 'list[str]' =None, reservation_quota_code: 'str' =None, reservation_quota_name: 'str' =None, reservation_quota_page_url: 'str' =None, resources: 'V1Resources' =None, secondary_instance_id: 'str' =None, slug: 'str' =None, slug_multi_cloud: 'str' =None, spot_price: 'float' =None, spot_quota_code: 'str' =None, spot_quota_name: 'str' =None, spot_quota_page_url: 'str' =None): # noqa: E501
|
|
159
|
+
def __init__(self, accelerator_type: 'str' =None, allowed_resources: 'list[str]' =None, availability_strategy: 'str' =None, available_in_seconds: 'str' =None, available_in_seconds_spot: 'str' =None, available_zones: 'list[str]' =None, byoc_only: 'bool' =None, capacity_block_only: 'bool' =None, capacity_block_price: 'float' =None, capacity_blocks_available: 'list[V1ClusterCapacityReservation]' =None, cluster_id: 'str' =None, cost: 'float' =None, detailed_quotas_info: 'list[V1AcceleratorQuotaInfo]' =None, device_card: 'str' =None, device_info: 'str' =None, display_name: 'str' =None, dws_cost: 'float' =None, dws_only: 'bool' =None, dws_supported: 'bool' =None, enabled: 'bool' =None, family: 'str' =None, instance_id: 'str' =None, is_custom: 'bool' =None, is_tier_restricted: 'bool' =None, lightning_interruptible: 'bool' =None, local_disk_included: 'bool' =None, local_disk_size: 'str' =None, local_disk_supported: 'bool' =None, local_disks_count: 'str' =None, max_available_quota: 'str' =None, non_spot: 'bool' =None, out_of_capacity: 'bool' =None, partitionable_parent: 'str' =None, persistent_disk_supported: 'bool' =None, provider: 'V1CloudProvider' =None, quota_checked_at: 'datetime' =None, quota_code: 'str' =None, quota_name: 'str' =None, quota_page_url: 'str' =None, quota_service_code: 'str' =None, quota_utilization: 'str' =None, quota_value: 'str' =None, reservable: 'bool' =None, reservation_available_zones: 'list[str]' =None, reservation_quota_code: 'str' =None, reservation_quota_name: 'str' =None, reservation_quota_page_url: 'str' =None, resources: 'V1Resources' =None, secondary_instance_id: 'str' =None, slug: 'str' =None, slug_multi_cloud: 'str' =None, spot_price: 'float' =None, spot_quota_code: 'str' =None, spot_quota_name: 'str' =None, spot_quota_page_url: 'str' =None): # noqa: E501
|
|
158
160
|
"""V1ClusterAccelerator - a model defined in Swagger""" # noqa: E501
|
|
159
161
|
self._accelerator_type = None
|
|
160
162
|
self._allowed_resources = None
|
|
@@ -188,6 +190,7 @@ class V1ClusterAccelerator(object):
|
|
|
188
190
|
self._max_available_quota = None
|
|
189
191
|
self._non_spot = None
|
|
190
192
|
self._out_of_capacity = None
|
|
193
|
+
self._partitionable_parent = None
|
|
191
194
|
self._persistent_disk_supported = None
|
|
192
195
|
self._provider = None
|
|
193
196
|
self._quota_checked_at = None
|
|
@@ -275,6 +278,8 @@ class V1ClusterAccelerator(object):
|
|
|
275
278
|
self.non_spot = non_spot
|
|
276
279
|
if out_of_capacity is not None:
|
|
277
280
|
self.out_of_capacity = out_of_capacity
|
|
281
|
+
if partitionable_parent is not None:
|
|
282
|
+
self.partitionable_parent = partitionable_parent
|
|
278
283
|
if persistent_disk_supported is not None:
|
|
279
284
|
self.persistent_disk_supported = persistent_disk_supported
|
|
280
285
|
if provider is not None:
|
|
@@ -992,6 +997,27 @@ class V1ClusterAccelerator(object):
|
|
|
992
997
|
|
|
993
998
|
self._out_of_capacity = out_of_capacity
|
|
994
999
|
|
|
1000
|
+
@property
|
|
1001
|
+
def partitionable_parent(self) -> 'str':
|
|
1002
|
+
"""Gets the partitionable_parent of this V1ClusterAccelerator. # noqa: E501
|
|
1003
|
+
|
|
1004
|
+
|
|
1005
|
+
:return: The partitionable_parent of this V1ClusterAccelerator. # noqa: E501
|
|
1006
|
+
:rtype: str
|
|
1007
|
+
"""
|
|
1008
|
+
return self._partitionable_parent
|
|
1009
|
+
|
|
1010
|
+
@partitionable_parent.setter
|
|
1011
|
+
def partitionable_parent(self, partitionable_parent: 'str'):
|
|
1012
|
+
"""Sets the partitionable_parent of this V1ClusterAccelerator.
|
|
1013
|
+
|
|
1014
|
+
|
|
1015
|
+
:param partitionable_parent: The partitionable_parent of this V1ClusterAccelerator. # noqa: E501
|
|
1016
|
+
:type: str
|
|
1017
|
+
"""
|
|
1018
|
+
|
|
1019
|
+
self._partitionable_parent = partitionable_parent
|
|
1020
|
+
|
|
995
1021
|
@property
|
|
996
1022
|
def persistent_disk_supported(self) -> 'bool':
|
|
997
1023
|
"""Gets the persistent_disk_supported of this V1ClusterAccelerator. # noqa: E501
|
|
@@ -57,6 +57,7 @@ class V1ClusterCapacityReservation(object):
|
|
|
57
57
|
'project_id': 'str',
|
|
58
58
|
'region': 'str',
|
|
59
59
|
'start_time': 'datetime',
|
|
60
|
+
'used_by': 'list[V1CapacityReservationUsedBy]',
|
|
60
61
|
'zone': 'str'
|
|
61
62
|
}
|
|
62
63
|
|
|
@@ -77,10 +78,11 @@ class V1ClusterCapacityReservation(object):
|
|
|
77
78
|
'project_id': 'projectId',
|
|
78
79
|
'region': 'region',
|
|
79
80
|
'start_time': 'startTime',
|
|
81
|
+
'used_by': 'usedBy',
|
|
80
82
|
'zone': 'zone'
|
|
81
83
|
}
|
|
82
84
|
|
|
83
|
-
def __init__(self, aggregate_availability: 'str' =None, capacity_reservation_type: 'str' =None, cloud_provider_capacity_reservation_id: 'str' =None, cluster_id: 'str' =None, end_time: 'datetime' =None, full_cloud_provider_reservation_string: 'str' =None, id: 'str' =None, in_use: 'str' =None, in_use_aggregate: 'str' =None, instance_type: 'str' =None, match_pattern: 'str' =None, node_group_name: 'str' =None, num_instances: 'str' =None, project_id: 'str' =None, region: 'str' =None, start_time: 'datetime' =None, zone: 'str' =None): # noqa: E501
|
|
85
|
+
def __init__(self, aggregate_availability: 'str' =None, capacity_reservation_type: 'str' =None, cloud_provider_capacity_reservation_id: 'str' =None, cluster_id: 'str' =None, end_time: 'datetime' =None, full_cloud_provider_reservation_string: 'str' =None, id: 'str' =None, in_use: 'str' =None, in_use_aggregate: 'str' =None, instance_type: 'str' =None, match_pattern: 'str' =None, node_group_name: 'str' =None, num_instances: 'str' =None, project_id: 'str' =None, region: 'str' =None, start_time: 'datetime' =None, used_by: 'list[V1CapacityReservationUsedBy]' =None, zone: 'str' =None): # noqa: E501
|
|
84
86
|
"""V1ClusterCapacityReservation - a model defined in Swagger""" # noqa: E501
|
|
85
87
|
self._aggregate_availability = None
|
|
86
88
|
self._capacity_reservation_type = None
|
|
@@ -98,6 +100,7 @@ class V1ClusterCapacityReservation(object):
|
|
|
98
100
|
self._project_id = None
|
|
99
101
|
self._region = None
|
|
100
102
|
self._start_time = None
|
|
103
|
+
self._used_by = None
|
|
101
104
|
self._zone = None
|
|
102
105
|
self.discriminator = None
|
|
103
106
|
if aggregate_availability is not None:
|
|
@@ -132,6 +135,8 @@ class V1ClusterCapacityReservation(object):
|
|
|
132
135
|
self.region = region
|
|
133
136
|
if start_time is not None:
|
|
134
137
|
self.start_time = start_time
|
|
138
|
+
if used_by is not None:
|
|
139
|
+
self.used_by = used_by
|
|
135
140
|
if zone is not None:
|
|
136
141
|
self.zone = zone
|
|
137
142
|
|
|
@@ -471,6 +476,27 @@ class V1ClusterCapacityReservation(object):
|
|
|
471
476
|
|
|
472
477
|
self._start_time = start_time
|
|
473
478
|
|
|
479
|
+
@property
|
|
480
|
+
def used_by(self) -> 'list[V1CapacityReservationUsedBy]':
|
|
481
|
+
"""Gets the used_by of this V1ClusterCapacityReservation. # noqa: E501
|
|
482
|
+
|
|
483
|
+
|
|
484
|
+
:return: The used_by of this V1ClusterCapacityReservation. # noqa: E501
|
|
485
|
+
:rtype: list[V1CapacityReservationUsedBy]
|
|
486
|
+
"""
|
|
487
|
+
return self._used_by
|
|
488
|
+
|
|
489
|
+
@used_by.setter
|
|
490
|
+
def used_by(self, used_by: 'list[V1CapacityReservationUsedBy]'):
|
|
491
|
+
"""Sets the used_by of this V1ClusterCapacityReservation.
|
|
492
|
+
|
|
493
|
+
|
|
494
|
+
:param used_by: The used_by of this V1ClusterCapacityReservation. # noqa: E501
|
|
495
|
+
:type: list[V1CapacityReservationUsedBy]
|
|
496
|
+
"""
|
|
497
|
+
|
|
498
|
+
self._used_by = used_by
|
|
499
|
+
|
|
474
500
|
@property
|
|
475
501
|
def zone(self) -> 'str':
|
|
476
502
|
"""Gets the zone of this V1ClusterCapacityReservation. # noqa: E501
|
|
@@ -41,7 +41,6 @@ class V1ClusterSpec(object):
|
|
|
41
41
|
and the value is json key in definition.
|
|
42
42
|
"""
|
|
43
43
|
swagger_types = {
|
|
44
|
-
'ai_pod_v1': 'V1AiPodV1',
|
|
45
44
|
'auth_token': 'str',
|
|
46
45
|
'available_accelerators': 'list[str]',
|
|
47
46
|
'aws_v1': 'V1AWSDirectV1',
|
|
@@ -50,6 +49,7 @@ class V1ClusterSpec(object):
|
|
|
50
49
|
'cluster_type': 'V1ClusterType',
|
|
51
50
|
'compute_cluster_ids': 'list[str]',
|
|
52
51
|
'compute_cluster_request': 'V1ComputeClusterRequest',
|
|
52
|
+
'cudo_v1': 'V1CudoDirectV1',
|
|
53
53
|
'deletion_options': 'V1ClusterDeletionOptions',
|
|
54
54
|
'desired_state': 'V1ClusterState',
|
|
55
55
|
'domain': 'str',
|
|
@@ -68,6 +68,7 @@ class V1ClusterSpec(object):
|
|
|
68
68
|
'overprovisioning': 'list[V1InstanceOverprovisioningSpec]',
|
|
69
69
|
'parent_cluster_id': 'str',
|
|
70
70
|
'parent_cluster_type': 'str',
|
|
71
|
+
'partitioning_enabled': 'bool',
|
|
71
72
|
'pause_automation': 'bool',
|
|
72
73
|
'reservation_details': 'V1ReservationDetails',
|
|
73
74
|
'reserved_capacity_provider': 'bool',
|
|
@@ -83,7 +84,6 @@ class V1ClusterSpec(object):
|
|
|
83
84
|
}
|
|
84
85
|
|
|
85
86
|
attribute_map = {
|
|
86
|
-
'ai_pod_v1': 'aiPodV1',
|
|
87
87
|
'auth_token': 'authToken',
|
|
88
88
|
'available_accelerators': 'availableAccelerators',
|
|
89
89
|
'aws_v1': 'awsV1',
|
|
@@ -92,6 +92,7 @@ class V1ClusterSpec(object):
|
|
|
92
92
|
'cluster_type': 'clusterType',
|
|
93
93
|
'compute_cluster_ids': 'computeClusterIds',
|
|
94
94
|
'compute_cluster_request': 'computeClusterRequest',
|
|
95
|
+
'cudo_v1': 'cudoV1',
|
|
95
96
|
'deletion_options': 'deletionOptions',
|
|
96
97
|
'desired_state': 'desiredState',
|
|
97
98
|
'domain': 'domain',
|
|
@@ -110,6 +111,7 @@ class V1ClusterSpec(object):
|
|
|
110
111
|
'overprovisioning': 'overprovisioning',
|
|
111
112
|
'parent_cluster_id': 'parentClusterId',
|
|
112
113
|
'parent_cluster_type': 'parentClusterType',
|
|
114
|
+
'partitioning_enabled': 'partitioningEnabled',
|
|
113
115
|
'pause_automation': 'pauseAutomation',
|
|
114
116
|
'reservation_details': 'reservationDetails',
|
|
115
117
|
'reserved_capacity_provider': 'reservedCapacityProvider',
|
|
@@ -124,9 +126,8 @@ class V1ClusterSpec(object):
|
|
|
124
126
|
'vultr_v1': 'vultrV1'
|
|
125
127
|
}
|
|
126
128
|
|
|
127
|
-
def __init__(self,
|
|
129
|
+
def __init__(self, auth_token: 'str' =None, available_accelerators: 'list[str]' =None, aws_v1: 'V1AWSDirectV1' =None, cloud_pricing_enabled: 'bool' =None, cloudflare_v1: 'V1CloudflareV1' =None, cluster_type: 'V1ClusterType' =None, compute_cluster_ids: 'list[str]' =None, compute_cluster_request: 'V1ComputeClusterRequest' =None, cudo_v1: 'V1CudoDirectV1' =None, deletion_options: 'V1ClusterDeletionOptions' =None, desired_state: 'V1ClusterState' =None, domain: 'str' =None, driver: 'V1CloudProvider' =None, freeze_accelerators: 'bool' =None, google_cloud_v1: 'V1GoogleCloudDirectV1' =None, insurer_disabled: 'bool' =None, kubernetes_v1: 'V1KubernetesDirectV1' =None, lambda_labs_v1: 'V1LambdaLabsDirectV1' =None, lightning_elastic_cluster_v1: 'V1LightningElasticClusterV1' =None, lock_overprovisioning: 'bool' =None, locked_zones: 'list[str]' =None, machine_v1: 'V1MachineDirectV1' =None, monitor_deletion_disabled: 'bool' =None, nebius_v1: 'V1NebiusDirectV1' =None, overprovisioning: 'list[V1InstanceOverprovisioningSpec]' =None, parent_cluster_id: 'str' =None, parent_cluster_type: 'str' =None, partitioning_enabled: 'bool' =None, pause_automation: 'bool' =None, reservation_details: 'V1ReservationDetails' =None, reserved_capacity_provider: 'bool' =None, reserved_instances_only: 'bool' =None, security_options: 'V1ClusterSecurityOptions' =None, slurm_v1: 'V1SlurmV1' =None, tagging_options: 'V1ClusterTaggingOptions' =None, unavailability_spikes_detection_enabled: 'bool' =None, user_id: 'str' =None, vibe_coding_enabled: 'bool' =None, voltage_park_v1: 'V1VoltageParkDirectV1' =None, vultr_v1: 'V1VultrDirectV1' =None): # noqa: E501
|
|
128
130
|
"""V1ClusterSpec - a model defined in Swagger""" # noqa: E501
|
|
129
|
-
self._ai_pod_v1 = None
|
|
130
131
|
self._auth_token = None
|
|
131
132
|
self._available_accelerators = None
|
|
132
133
|
self._aws_v1 = None
|
|
@@ -135,6 +136,7 @@ class V1ClusterSpec(object):
|
|
|
135
136
|
self._cluster_type = None
|
|
136
137
|
self._compute_cluster_ids = None
|
|
137
138
|
self._compute_cluster_request = None
|
|
139
|
+
self._cudo_v1 = None
|
|
138
140
|
self._deletion_options = None
|
|
139
141
|
self._desired_state = None
|
|
140
142
|
self._domain = None
|
|
@@ -153,6 +155,7 @@ class V1ClusterSpec(object):
|
|
|
153
155
|
self._overprovisioning = None
|
|
154
156
|
self._parent_cluster_id = None
|
|
155
157
|
self._parent_cluster_type = None
|
|
158
|
+
self._partitioning_enabled = None
|
|
156
159
|
self._pause_automation = None
|
|
157
160
|
self._reservation_details = None
|
|
158
161
|
self._reserved_capacity_provider = None
|
|
@@ -166,8 +169,6 @@ class V1ClusterSpec(object):
|
|
|
166
169
|
self._voltage_park_v1 = None
|
|
167
170
|
self._vultr_v1 = None
|
|
168
171
|
self.discriminator = None
|
|
169
|
-
if ai_pod_v1 is not None:
|
|
170
|
-
self.ai_pod_v1 = ai_pod_v1
|
|
171
172
|
if auth_token is not None:
|
|
172
173
|
self.auth_token = auth_token
|
|
173
174
|
if available_accelerators is not None:
|
|
@@ -184,6 +185,8 @@ class V1ClusterSpec(object):
|
|
|
184
185
|
self.compute_cluster_ids = compute_cluster_ids
|
|
185
186
|
if compute_cluster_request is not None:
|
|
186
187
|
self.compute_cluster_request = compute_cluster_request
|
|
188
|
+
if cudo_v1 is not None:
|
|
189
|
+
self.cudo_v1 = cudo_v1
|
|
187
190
|
if deletion_options is not None:
|
|
188
191
|
self.deletion_options = deletion_options
|
|
189
192
|
if desired_state is not None:
|
|
@@ -220,6 +223,8 @@ class V1ClusterSpec(object):
|
|
|
220
223
|
self.parent_cluster_id = parent_cluster_id
|
|
221
224
|
if parent_cluster_type is not None:
|
|
222
225
|
self.parent_cluster_type = parent_cluster_type
|
|
226
|
+
if partitioning_enabled is not None:
|
|
227
|
+
self.partitioning_enabled = partitioning_enabled
|
|
223
228
|
if pause_automation is not None:
|
|
224
229
|
self.pause_automation = pause_automation
|
|
225
230
|
if reservation_details is not None:
|
|
@@ -245,27 +250,6 @@ class V1ClusterSpec(object):
|
|
|
245
250
|
if vultr_v1 is not None:
|
|
246
251
|
self.vultr_v1 = vultr_v1
|
|
247
252
|
|
|
248
|
-
@property
|
|
249
|
-
def ai_pod_v1(self) -> 'V1AiPodV1':
|
|
250
|
-
"""Gets the ai_pod_v1 of this V1ClusterSpec. # noqa: E501
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
:return: The ai_pod_v1 of this V1ClusterSpec. # noqa: E501
|
|
254
|
-
:rtype: V1AiPodV1
|
|
255
|
-
"""
|
|
256
|
-
return self._ai_pod_v1
|
|
257
|
-
|
|
258
|
-
@ai_pod_v1.setter
|
|
259
|
-
def ai_pod_v1(self, ai_pod_v1: 'V1AiPodV1'):
|
|
260
|
-
"""Sets the ai_pod_v1 of this V1ClusterSpec.
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
:param ai_pod_v1: The ai_pod_v1 of this V1ClusterSpec. # noqa: E501
|
|
264
|
-
:type: V1AiPodV1
|
|
265
|
-
"""
|
|
266
|
-
|
|
267
|
-
self._ai_pod_v1 = ai_pod_v1
|
|
268
|
-
|
|
269
253
|
@property
|
|
270
254
|
def auth_token(self) -> 'str':
|
|
271
255
|
"""Gets the auth_token of this V1ClusterSpec. # noqa: E501
|
|
@@ -434,6 +418,27 @@ class V1ClusterSpec(object):
|
|
|
434
418
|
|
|
435
419
|
self._compute_cluster_request = compute_cluster_request
|
|
436
420
|
|
|
421
|
+
@property
|
|
422
|
+
def cudo_v1(self) -> 'V1CudoDirectV1':
|
|
423
|
+
"""Gets the cudo_v1 of this V1ClusterSpec. # noqa: E501
|
|
424
|
+
|
|
425
|
+
|
|
426
|
+
:return: The cudo_v1 of this V1ClusterSpec. # noqa: E501
|
|
427
|
+
:rtype: V1CudoDirectV1
|
|
428
|
+
"""
|
|
429
|
+
return self._cudo_v1
|
|
430
|
+
|
|
431
|
+
@cudo_v1.setter
|
|
432
|
+
def cudo_v1(self, cudo_v1: 'V1CudoDirectV1'):
|
|
433
|
+
"""Sets the cudo_v1 of this V1ClusterSpec.
|
|
434
|
+
|
|
435
|
+
|
|
436
|
+
:param cudo_v1: The cudo_v1 of this V1ClusterSpec. # noqa: E501
|
|
437
|
+
:type: V1CudoDirectV1
|
|
438
|
+
"""
|
|
439
|
+
|
|
440
|
+
self._cudo_v1 = cudo_v1
|
|
441
|
+
|
|
437
442
|
@property
|
|
438
443
|
def deletion_options(self) -> 'V1ClusterDeletionOptions':
|
|
439
444
|
"""Gets the deletion_options of this V1ClusterSpec. # noqa: E501
|
|
@@ -814,6 +819,27 @@ class V1ClusterSpec(object):
|
|
|
814
819
|
|
|
815
820
|
self._parent_cluster_type = parent_cluster_type
|
|
816
821
|
|
|
822
|
+
@property
|
|
823
|
+
def partitioning_enabled(self) -> 'bool':
|
|
824
|
+
"""Gets the partitioning_enabled of this V1ClusterSpec. # noqa: E501
|
|
825
|
+
|
|
826
|
+
|
|
827
|
+
:return: The partitioning_enabled of this V1ClusterSpec. # noqa: E501
|
|
828
|
+
:rtype: bool
|
|
829
|
+
"""
|
|
830
|
+
return self._partitioning_enabled
|
|
831
|
+
|
|
832
|
+
@partitioning_enabled.setter
|
|
833
|
+
def partitioning_enabled(self, partitioning_enabled: 'bool'):
|
|
834
|
+
"""Sets the partitioning_enabled of this V1ClusterSpec.
|
|
835
|
+
|
|
836
|
+
|
|
837
|
+
:param partitioning_enabled: The partitioning_enabled of this V1ClusterSpec. # noqa: E501
|
|
838
|
+
:type: bool
|
|
839
|
+
"""
|
|
840
|
+
|
|
841
|
+
self._partitioning_enabled = partitioning_enabled
|
|
842
|
+
|
|
817
843
|
@property
|
|
818
844
|
def pause_automation(self) -> 'bool':
|
|
819
845
|
"""Gets the pause_automation of this V1ClusterSpec. # noqa: E501
|
|
@@ -0,0 +1,253 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
external/v1/auth_service.proto
|
|
5
|
+
|
|
6
|
+
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
|
|
7
|
+
|
|
8
|
+
OpenAPI spec version: version not set
|
|
9
|
+
|
|
10
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
|
11
|
+
|
|
12
|
+
NOTE
|
|
13
|
+
----
|
|
14
|
+
standard swagger-codegen-cli for this python client has been modified
|
|
15
|
+
by custom templates. The purpose of these templates is to include
|
|
16
|
+
typing information in the API and Model code. Please refer to the
|
|
17
|
+
main grid repository for more info
|
|
18
|
+
"""
|
|
19
|
+
|
|
20
|
+
import pprint
|
|
21
|
+
import re # noqa: F401
|
|
22
|
+
|
|
23
|
+
from typing import TYPE_CHECKING
|
|
24
|
+
|
|
25
|
+
import six
|
|
26
|
+
|
|
27
|
+
if TYPE_CHECKING:
|
|
28
|
+
from datetime import datetime
|
|
29
|
+
from lightning_sdk.lightning_cloud.openapi.models import *
|
|
30
|
+
|
|
31
|
+
class V1ContainerRegistry(object):
|
|
32
|
+
"""NOTE: This class is auto generated by the swagger code generator program.
|
|
33
|
+
|
|
34
|
+
Do not edit the class manually.
|
|
35
|
+
"""
|
|
36
|
+
"""
|
|
37
|
+
Attributes:
|
|
38
|
+
swagger_types (dict): The key is attribute name
|
|
39
|
+
and the value is attribute type.
|
|
40
|
+
attribute_map (dict): The key is attribute name
|
|
41
|
+
and the value is json key in definition.
|
|
42
|
+
"""
|
|
43
|
+
swagger_types = {
|
|
44
|
+
'ecr': 'V1ECRRegistryConfig',
|
|
45
|
+
'id': 'str',
|
|
46
|
+
'last_refresh': 'datetime',
|
|
47
|
+
'status': 'V1ContainerRegistryStatus',
|
|
48
|
+
'status_message': 'str',
|
|
49
|
+
'validated_at': 'datetime'
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
attribute_map = {
|
|
53
|
+
'ecr': 'ecr',
|
|
54
|
+
'id': 'id',
|
|
55
|
+
'last_refresh': 'lastRefresh',
|
|
56
|
+
'status': 'status',
|
|
57
|
+
'status_message': 'statusMessage',
|
|
58
|
+
'validated_at': 'validatedAt'
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
def __init__(self, ecr: 'V1ECRRegistryConfig' =None, id: 'str' =None, last_refresh: 'datetime' =None, status: 'V1ContainerRegistryStatus' =None, status_message: 'str' =None, validated_at: 'datetime' =None): # noqa: E501
|
|
62
|
+
"""V1ContainerRegistry - a model defined in Swagger""" # noqa: E501
|
|
63
|
+
self._ecr = None
|
|
64
|
+
self._id = None
|
|
65
|
+
self._last_refresh = None
|
|
66
|
+
self._status = None
|
|
67
|
+
self._status_message = None
|
|
68
|
+
self._validated_at = None
|
|
69
|
+
self.discriminator = None
|
|
70
|
+
if ecr is not None:
|
|
71
|
+
self.ecr = ecr
|
|
72
|
+
if id is not None:
|
|
73
|
+
self.id = id
|
|
74
|
+
if last_refresh is not None:
|
|
75
|
+
self.last_refresh = last_refresh
|
|
76
|
+
if status is not None:
|
|
77
|
+
self.status = status
|
|
78
|
+
if status_message is not None:
|
|
79
|
+
self.status_message = status_message
|
|
80
|
+
if validated_at is not None:
|
|
81
|
+
self.validated_at = validated_at
|
|
82
|
+
|
|
83
|
+
@property
|
|
84
|
+
def ecr(self) -> 'V1ECRRegistryConfig':
|
|
85
|
+
"""Gets the ecr of this V1ContainerRegistry. # noqa: E501
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
:return: The ecr of this V1ContainerRegistry. # noqa: E501
|
|
89
|
+
:rtype: V1ECRRegistryConfig
|
|
90
|
+
"""
|
|
91
|
+
return self._ecr
|
|
92
|
+
|
|
93
|
+
@ecr.setter
|
|
94
|
+
def ecr(self, ecr: 'V1ECRRegistryConfig'):
|
|
95
|
+
"""Sets the ecr of this V1ContainerRegistry.
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
:param ecr: The ecr of this V1ContainerRegistry. # noqa: E501
|
|
99
|
+
:type: V1ECRRegistryConfig
|
|
100
|
+
"""
|
|
101
|
+
|
|
102
|
+
self._ecr = ecr
|
|
103
|
+
|
|
104
|
+
@property
|
|
105
|
+
def id(self) -> 'str':
|
|
106
|
+
"""Gets the id of this V1ContainerRegistry. # noqa: E501
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
:return: The id of this V1ContainerRegistry. # noqa: E501
|
|
110
|
+
:rtype: str
|
|
111
|
+
"""
|
|
112
|
+
return self._id
|
|
113
|
+
|
|
114
|
+
@id.setter
|
|
115
|
+
def id(self, id: 'str'):
|
|
116
|
+
"""Sets the id of this V1ContainerRegistry.
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
:param id: The id of this V1ContainerRegistry. # noqa: E501
|
|
120
|
+
:type: str
|
|
121
|
+
"""
|
|
122
|
+
|
|
123
|
+
self._id = id
|
|
124
|
+
|
|
125
|
+
@property
|
|
126
|
+
def last_refresh(self) -> 'datetime':
|
|
127
|
+
"""Gets the last_refresh of this V1ContainerRegistry. # noqa: E501
|
|
128
|
+
|
|
129
|
+
|
|
130
|
+
:return: The last_refresh of this V1ContainerRegistry. # noqa: E501
|
|
131
|
+
:rtype: datetime
|
|
132
|
+
"""
|
|
133
|
+
return self._last_refresh
|
|
134
|
+
|
|
135
|
+
@last_refresh.setter
|
|
136
|
+
def last_refresh(self, last_refresh: 'datetime'):
|
|
137
|
+
"""Sets the last_refresh of this V1ContainerRegistry.
|
|
138
|
+
|
|
139
|
+
|
|
140
|
+
:param last_refresh: The last_refresh of this V1ContainerRegistry. # noqa: E501
|
|
141
|
+
:type: datetime
|
|
142
|
+
"""
|
|
143
|
+
|
|
144
|
+
self._last_refresh = last_refresh
|
|
145
|
+
|
|
146
|
+
@property
|
|
147
|
+
def status(self) -> 'V1ContainerRegistryStatus':
|
|
148
|
+
"""Gets the status of this V1ContainerRegistry. # noqa: E501
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
:return: The status of this V1ContainerRegistry. # noqa: E501
|
|
152
|
+
:rtype: V1ContainerRegistryStatus
|
|
153
|
+
"""
|
|
154
|
+
return self._status
|
|
155
|
+
|
|
156
|
+
@status.setter
|
|
157
|
+
def status(self, status: 'V1ContainerRegistryStatus'):
|
|
158
|
+
"""Sets the status of this V1ContainerRegistry.
|
|
159
|
+
|
|
160
|
+
|
|
161
|
+
:param status: The status of this V1ContainerRegistry. # noqa: E501
|
|
162
|
+
:type: V1ContainerRegistryStatus
|
|
163
|
+
"""
|
|
164
|
+
|
|
165
|
+
self._status = status
|
|
166
|
+
|
|
167
|
+
@property
|
|
168
|
+
def status_message(self) -> 'str':
|
|
169
|
+
"""Gets the status_message of this V1ContainerRegistry. # noqa: E501
|
|
170
|
+
|
|
171
|
+
|
|
172
|
+
:return: The status_message of this V1ContainerRegistry. # noqa: E501
|
|
173
|
+
:rtype: str
|
|
174
|
+
"""
|
|
175
|
+
return self._status_message
|
|
176
|
+
|
|
177
|
+
@status_message.setter
|
|
178
|
+
def status_message(self, status_message: 'str'):
|
|
179
|
+
"""Sets the status_message of this V1ContainerRegistry.
|
|
180
|
+
|
|
181
|
+
|
|
182
|
+
:param status_message: The status_message of this V1ContainerRegistry. # noqa: E501
|
|
183
|
+
:type: str
|
|
184
|
+
"""
|
|
185
|
+
|
|
186
|
+
self._status_message = status_message
|
|
187
|
+
|
|
188
|
+
@property
|
|
189
|
+
def validated_at(self) -> 'datetime':
|
|
190
|
+
"""Gets the validated_at of this V1ContainerRegistry. # noqa: E501
|
|
191
|
+
|
|
192
|
+
|
|
193
|
+
:return: The validated_at of this V1ContainerRegistry. # noqa: E501
|
|
194
|
+
:rtype: datetime
|
|
195
|
+
"""
|
|
196
|
+
return self._validated_at
|
|
197
|
+
|
|
198
|
+
@validated_at.setter
|
|
199
|
+
def validated_at(self, validated_at: 'datetime'):
|
|
200
|
+
"""Sets the validated_at of this V1ContainerRegistry.
|
|
201
|
+
|
|
202
|
+
|
|
203
|
+
:param validated_at: The validated_at of this V1ContainerRegistry. # noqa: E501
|
|
204
|
+
:type: datetime
|
|
205
|
+
"""
|
|
206
|
+
|
|
207
|
+
self._validated_at = validated_at
|
|
208
|
+
|
|
209
|
+
def to_dict(self) -> dict:
|
|
210
|
+
"""Returns the model properties as a dict"""
|
|
211
|
+
result = {}
|
|
212
|
+
|
|
213
|
+
for attr, _ in six.iteritems(self.swagger_types):
|
|
214
|
+
value = getattr(self, attr)
|
|
215
|
+
if isinstance(value, list):
|
|
216
|
+
result[attr] = list(map(
|
|
217
|
+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
|
218
|
+
value
|
|
219
|
+
))
|
|
220
|
+
elif hasattr(value, "to_dict"):
|
|
221
|
+
result[attr] = value.to_dict()
|
|
222
|
+
elif isinstance(value, dict):
|
|
223
|
+
result[attr] = dict(map(
|
|
224
|
+
lambda item: (item[0], item[1].to_dict())
|
|
225
|
+
if hasattr(item[1], "to_dict") else item,
|
|
226
|
+
value.items()
|
|
227
|
+
))
|
|
228
|
+
else:
|
|
229
|
+
result[attr] = value
|
|
230
|
+
if issubclass(V1ContainerRegistry, dict):
|
|
231
|
+
for key, value in self.items():
|
|
232
|
+
result[key] = value
|
|
233
|
+
|
|
234
|
+
return result
|
|
235
|
+
|
|
236
|
+
def to_str(self) -> str:
|
|
237
|
+
"""Returns the string representation of the model"""
|
|
238
|
+
return pprint.pformat(self.to_dict())
|
|
239
|
+
|
|
240
|
+
def __repr__(self) -> str:
|
|
241
|
+
"""For `print` and `pprint`"""
|
|
242
|
+
return self.to_str()
|
|
243
|
+
|
|
244
|
+
def __eq__(self, other: 'V1ContainerRegistry') -> bool:
|
|
245
|
+
"""Returns true if both objects are equal"""
|
|
246
|
+
if not isinstance(other, V1ContainerRegistry):
|
|
247
|
+
return False
|
|
248
|
+
|
|
249
|
+
return self.__dict__ == other.__dict__
|
|
250
|
+
|
|
251
|
+
def __ne__(self, other: 'V1ContainerRegistry') -> bool:
|
|
252
|
+
"""Returns true if both objects are not equal"""
|
|
253
|
+
return not self == other
|