Skip to content

Commit ac8c4a0

Browse files
authored
[azure][fix]: Fix unnecessary abstract class kinds (#2191)
1 parent 62a867e commit ac8c4a0

File tree

1 file changed

+32
-30
lines changed

1 file changed

+32
-30
lines changed

plugins/azure/fix_plugin_azure/resource/machinelearning.py

Lines changed: 32 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ def connect_in_graph(self, builder: GraphBuilder, source: Json) -> None:
122122

123123

124124
@define(eq=False, slots=False)
125-
class AzureMachineLearningCodeContainerBase(MicrosoftResource, AzureProxyResource):
125+
class AzureMachineLearningCodeContainerBase(AzureProxyResource):
126126
kind: ClassVar[str] = "azure_machine_learning_code_container_base"
127127
kind_display: ClassVar[str] = "Azure Machine Learning Code Container Base"
128128
kind_service: ClassVar[Optional[str]] = service_name
@@ -149,7 +149,7 @@ class AzureMachineLearningCodeContainerBase(MicrosoftResource, AzureProxyResourc
149149

150150

151151
@define(eq=False, slots=False)
152-
class AzureMachineLearningWorkspaceCodeContainer(AzureMachineLearningCodeContainerBase):
152+
class AzureMachineLearningWorkspaceCodeContainer(AzureMachineLearningCodeContainerBase, MicrosoftResource):
153153
# Defined to split registry and workspace resource
154154
kind: ClassVar[str] = "azure_machine_learning_workspace_code_container"
155155
kind_display: ClassVar[str] = "Azure Machine Learning Workspace Code Container"
@@ -185,7 +185,7 @@ def collect_versions() -> None:
185185

186186

187187
@define(eq=False, slots=False)
188-
class AzureMachineLearningRegistryCodeContainer(AzureMachineLearningCodeContainerBase):
188+
class AzureMachineLearningRegistryCodeContainer(AzureMachineLearningCodeContainerBase, MicrosoftResource):
189189
# Defined to split registry and workspace resource
190190
kind: ClassVar[str] = "azure_machine_learning_registry_code_container"
191191
kind_display: ClassVar[str] = "Azure Machine Learning Registry Code Container"
@@ -221,7 +221,7 @@ def collect_versions() -> None:
221221

222222

223223
@define(eq=False, slots=False)
224-
class AzureMachineLearningCodeVersionBase(CheckVersionIsArchived, MicrosoftResource, AzureProxyResource):
224+
class AzureMachineLearningCodeVersionBase(CheckVersionIsArchived, AzureProxyResource):
225225
kind: ClassVar[str] = "azure_machine_learning_code_version_base"
226226
kind_display: ClassVar[str] = "Azure Machine Learning Code Version Base"
227227
kind_service: ClassVar[Optional[str]] = service_name
@@ -248,22 +248,22 @@ class AzureMachineLearningCodeVersionBase(CheckVersionIsArchived, MicrosoftResou
248248

249249

250250
@define(eq=False, slots=False)
251-
class AzureMachineLearningWorkspaceCodeVersion(AzureMachineLearningCodeVersionBase):
251+
class AzureMachineLearningWorkspaceCodeVersion(AzureMachineLearningCodeVersionBase, MicrosoftResource):
252252
# Defined to split registry and workspace resource
253253
kind: ClassVar[str] = "azure_machine_learning_workspace_code_version"
254254
kind_display: ClassVar[str] = "Azure Machine Learning Workspace Code Version"
255255

256256

257257
@define(eq=False, slots=False)
258-
class AzureMachineLearningRegistryCodeVersion(AzureMachineLearningCodeVersionBase):
258+
class AzureMachineLearningRegistryCodeVersion(AzureMachineLearningCodeVersionBase, MicrosoftResource):
259259
# Defined to split registry and workspace resource
260260
kind: ClassVar[str] = "azure_machine_learning_registry_code_version"
261261
kind_display: ClassVar[str] = "Azure Machine Learning Registry Code Version"
262262
metadata: ClassVar[Dict[str, Any]] = {"icon": "version", "group": "generative_ai"}
263263

264264

265265
@define(eq=False, slots=False)
266-
class AzureMachineLearningComponentContainerBase(MicrosoftResource, AzureProxyResource):
266+
class AzureMachineLearningComponentContainerBase(AzureProxyResource):
267267
kind: ClassVar[str] = "azure_machine_learning_component_container_base"
268268
kind_display: ClassVar[str] = "Azure Machine Learning Component Container Base"
269269
kind_service: ClassVar[Optional[str]] = service_name
@@ -290,7 +290,7 @@ class AzureMachineLearningComponentContainerBase(MicrosoftResource, AzureProxyRe
290290

291291

292292
@define(eq=False, slots=False)
293-
class AzureMachineLearningWorkspaceComponentContainer(AzureMachineLearningComponentContainerBase):
293+
class AzureMachineLearningWorkspaceComponentContainer(AzureMachineLearningComponentContainerBase, MicrosoftResource):
294294
# Defined to split registry and workspace resource
295295

296296
kind: ClassVar[str] = "azure_machine_learning_workspace_component_container"
@@ -327,7 +327,7 @@ def collect_versions() -> None:
327327

328328

329329
@define(eq=False, slots=False)
330-
class AzureMachineLearningRegistryComponentContainer(AzureMachineLearningComponentContainerBase):
330+
class AzureMachineLearningRegistryComponentContainer(AzureMachineLearningComponentContainerBase, MicrosoftResource):
331331
# Defined to split registry and workspace resource
332332

333333
kind: ClassVar[str] = "azure_machine_learning_registry_component_container"
@@ -364,7 +364,7 @@ def collect_versions() -> None:
364364

365365

366366
@define(eq=False, slots=False)
367-
class AzureMachineLearningComponentVersionBase(CheckVersionIsArchived, MicrosoftResource, AzureProxyResource):
367+
class AzureMachineLearningComponentVersionBase(CheckVersionIsArchived, AzureProxyResource):
368368
kind: ClassVar[str] = "azure_machine_learning_component_version_base"
369369
kind_display: ClassVar[str] = "Azure Machine Learning Component Version Base"
370370
kind_service: ClassVar[Optional[str]] = service_name
@@ -392,15 +392,15 @@ class AzureMachineLearningComponentVersionBase(CheckVersionIsArchived, Microsoft
392392

393393

394394
@define(eq=False, slots=False)
395-
class AzureMachineLearningWorkspaceComponentVersion(AzureMachineLearningComponentVersionBase):
395+
class AzureMachineLearningWorkspaceComponentVersion(AzureMachineLearningComponentVersionBase, MicrosoftResource):
396396
# Defined to split registry and workspace resource
397397

398398
kind: ClassVar[str] = "azure_machine_learning_workspace_component_version"
399399
kind_display: ClassVar[str] = "Azure Machine Learning Workspace Component Version"
400400

401401

402402
@define(eq=False, slots=False)
403-
class AzureMachineLearningRegistryComponentVersion(AzureMachineLearningComponentVersionBase):
403+
class AzureMachineLearningRegistryComponentVersion(AzureMachineLearningComponentVersionBase, MicrosoftResource):
404404
# Defined to split registry and workspace resource
405405

406406
kind: ClassVar[str] = "azure_machine_learning_registry_component_version"
@@ -590,7 +590,7 @@ def connect_in_graph(self, builder: GraphBuilder, source: Json) -> None:
590590

591591

592592
@define(eq=False, slots=False)
593-
class AzureMachineLearningDataContainerBase(MicrosoftResource, AzureProxyResource):
593+
class AzureMachineLearningDataContainerBase(AzureProxyResource):
594594
kind: ClassVar[str] = "azure_machine_learning_data_container_base"
595595
kind_display: ClassVar[str] = "Azure Machine Learning Data Container Base"
596596
kind_service: ClassVar[Optional[str]] = service_name
@@ -617,7 +617,7 @@ class AzureMachineLearningDataContainerBase(MicrosoftResource, AzureProxyResourc
617617

618618

619619
@define(eq=False, slots=False)
620-
class AzureMachineLearningWorkspaceDataContainer(AzureMachineLearningDataContainerBase):
620+
class AzureMachineLearningWorkspaceDataContainer(AzureMachineLearningDataContainerBase, MicrosoftResource):
621621
# Defined to split registry and workspace resource
622622

623623
kind: ClassVar[str] = "azure_machine_learning_workspace_data_container"
@@ -654,7 +654,7 @@ def collect_versions() -> None:
654654

655655

656656
@define(eq=False, slots=False)
657-
class AzureMachineLearningRegistryDataContainer(AzureMachineLearningDataContainerBase):
657+
class AzureMachineLearningRegistryDataContainer(AzureMachineLearningDataContainerBase, MicrosoftResource):
658658
# Defined to split registry and workspace resource
659659

660660
kind: ClassVar[str] = "azure_machine_learning_registry_data_container"
@@ -691,7 +691,7 @@ def collect_versions() -> None:
691691

692692

693693
@define(eq=False, slots=False)
694-
class AzureMachineLearningDataVersionBase(CheckVersionIsArchived, MicrosoftResource, AzureProxyResource):
694+
class AzureMachineLearningDataVersionBase(CheckVersionIsArchived, AzureProxyResource):
695695
kind: ClassVar[str] = "azure_machine_learning_data_version_base"
696696
kind_display: ClassVar[str] = "Azure Machine Learning Data Version Base"
697697
kind_service: ClassVar[Optional[str]] = service_name
@@ -721,15 +721,15 @@ class AzureMachineLearningDataVersionBase(CheckVersionIsArchived, MicrosoftResou
721721

722722

723723
@define(eq=False, slots=False)
724-
class AzureMachineLearningWorkspaceDataVersion(AzureMachineLearningDataVersionBase):
724+
class AzureMachineLearningWorkspaceDataVersion(AzureMachineLearningDataVersionBase, MicrosoftResource):
725725
# Defined to split registry and workspace resource
726726

727727
kind: ClassVar[str] = "azure_machine_learning_workspace_data_version"
728728
kind_display: ClassVar[str] = "Azure Machine Learning Workspace Data Version"
729729

730730

731731
@define(eq=False, slots=False)
732-
class AzureMachineLearningRegistryDataVersion(AzureMachineLearningDataVersionBase):
732+
class AzureMachineLearningRegistryDataVersion(AzureMachineLearningDataVersionBase, MicrosoftResource):
733733
# Defined to split registry and workspace resource
734734

735735
kind: ClassVar[str] = "azure_machine_learning_registry_data_version"
@@ -844,7 +844,7 @@ class AzureInferenceContainerProperties:
844844

845845

846846
@define(eq=False, slots=False)
847-
class AzureMachineLearningEnvironmentContainerBase(MicrosoftResource, AzureProxyResource):
847+
class AzureMachineLearningEnvironmentContainerBase(AzureProxyResource):
848848
kind: ClassVar[str] = "azure_machine_learning_environment_container_base"
849849
kind_display: ClassVar[str] = "Azure Machine Learning Environment Container Base"
850850
kind_service: ClassVar[Optional[str]] = service_name
@@ -871,7 +871,9 @@ class AzureMachineLearningEnvironmentContainerBase(MicrosoftResource, AzureProxy
871871

872872

873873
@define(eq=False, slots=False)
874-
class AzureMachineLearningWorkspaceEnvironmentContainer(AzureMachineLearningEnvironmentContainerBase):
874+
class AzureMachineLearningWorkspaceEnvironmentContainer(
875+
AzureMachineLearningEnvironmentContainerBase, MicrosoftResource
876+
):
875877
# Defined to split registry and workspace resource
876878

877879
kind: ClassVar[str] = "azure_machine_learning_workspace_environment_container"
@@ -908,7 +910,7 @@ def collect_versions() -> None:
908910

909911

910912
@define(eq=False, slots=False)
911-
class AzureMachineLearningRegistryEnvironmentContainer(AzureMachineLearningEnvironmentContainerBase):
913+
class AzureMachineLearningRegistryEnvironmentContainer(AzureMachineLearningEnvironmentContainerBase, MicrosoftResource):
912914
# Defined to split registry and workspace resource
913915

914916
kind: ClassVar[str] = "azure_machine_learning_registry_environment_container"
@@ -945,7 +947,7 @@ def collect_versions() -> None:
945947

946948

947949
@define(eq=False, slots=False)
948-
class AzureMachineLearningEnvironmentVersionBase(CheckVersionIsArchived, MicrosoftResource, AzureProxyResource):
950+
class AzureMachineLearningEnvironmentVersionBase(CheckVersionIsArchived, AzureProxyResource):
949951
kind: ClassVar[str] = "azure_machine_learning_environment_version_base"
950952
kind_display: ClassVar[str] = "Azure Machine Learning Environment Version Base"
951953
kind_service: ClassVar[Optional[str]] = service_name
@@ -987,15 +989,15 @@ class AzureMachineLearningEnvironmentVersionBase(CheckVersionIsArchived, Microso
987989

988990

989991
@define(eq=False, slots=False)
990-
class AzureMachineLearningWorkspaceEnvironmentVersion(AzureMachineLearningEnvironmentVersionBase):
992+
class AzureMachineLearningWorkspaceEnvironmentVersion(AzureMachineLearningEnvironmentVersionBase, MicrosoftResource):
991993
# Defined to split registry and workspace resource
992994

993995
kind: ClassVar[str] = "azure_machine_learning_workspace_environment_version"
994996
kind_display: ClassVar[str] = "Azure Machine Learning Workspace Environment Version"
995997

996998

997999
@define(eq=False, slots=False)
998-
class AzureMachineLearningRegistryEnvironmentVersion(AzureMachineLearningEnvironmentVersionBase):
1000+
class AzureMachineLearningRegistryEnvironmentVersion(AzureMachineLearningEnvironmentVersionBase, MicrosoftResource):
9991001
# Defined to split registry and workspace resource
10001002

10011003
kind: ClassVar[str] = "azure_machine_learning_registry_environment_version"
@@ -1552,7 +1554,7 @@ class AzureMachineLearningLabelingJob(MicrosoftResource):
15521554

15531555

15541556
@define(eq=False, slots=False)
1555-
class AzureMachineLearningModelContainerBase(MicrosoftResource, AzureProxyResource):
1557+
class AzureMachineLearningModelContainerBase(AzureProxyResource):
15561558
kind: ClassVar[str] = "azure_machine_learning_model_container_base"
15571559
kind_display: ClassVar[str] = "Azure Machine Learning Model Container Base"
15581560
kind_service: ClassVar[Optional[str]] = service_name
@@ -1579,7 +1581,7 @@ class AzureMachineLearningModelContainerBase(MicrosoftResource, AzureProxyResour
15791581

15801582

15811583
@define(eq=False, slots=False)
1582-
class AzureMachineLearningWorkspaceModelContainer(AzureMachineLearningModelContainerBase):
1584+
class AzureMachineLearningWorkspaceModelContainer(AzureMachineLearningModelContainerBase, MicrosoftResource):
15831585
# Defined to split registry and workspace resource
15841586

15851587
kind: ClassVar[str] = "azure_machine_learning_workspace_model_container"
@@ -1616,7 +1618,7 @@ def collect_versions() -> None:
16161618

16171619

16181620
@define(eq=False, slots=False)
1619-
class AzureMachineLearningRegistryModelContainer(AzureMachineLearningModelContainerBase):
1621+
class AzureMachineLearningRegistryModelContainer(AzureMachineLearningModelContainerBase, MicrosoftResource):
16201622
# Defined to split registry and workspace resource
16211623

16221624
kind: ClassVar[str] = "azure_machine_learning_registry_model_container"
@@ -1660,7 +1662,7 @@ class AzureFlavorData:
16601662

16611663

16621664
@define(eq=False, slots=False)
1663-
class AzureMachineLearningModelVersionBase(CheckVersionIsArchived, MicrosoftResource, AzureProxyResource):
1665+
class AzureMachineLearningModelVersionBase(CheckVersionIsArchived, AzureProxyResource):
16641666
kind: ClassVar[str] = "azure_machine_learning_base_model_version"
16651667
kind_display: ClassVar[str] = "Azure Machine Learning Base Model Version"
16661668
kind_service: ClassVar[Optional[str]] = service_name
@@ -1696,15 +1698,15 @@ class AzureMachineLearningModelVersionBase(CheckVersionIsArchived, MicrosoftReso
16961698

16971699

16981700
@define(eq=False, slots=False)
1699-
class AzureMachineLearningWorkspaceModelVersion(AzureMachineLearningModelVersionBase):
1701+
class AzureMachineLearningWorkspaceModelVersion(AzureMachineLearningModelVersionBase, MicrosoftResource):
17001702
# Defined to split registry and workspace resource
17011703

17021704
kind: ClassVar[str] = "azure_machine_learning_workspace_model_version"
17031705
kind_display: ClassVar[str] = "Azure Machine Learning Workspace Model Version"
17041706

17051707

17061708
@define(eq=False, slots=False)
1707-
class AzureMachineLearningRegistryModelVersion(AzureMachineLearningModelVersionBase):
1709+
class AzureMachineLearningRegistryModelVersion(AzureMachineLearningModelVersionBase, MicrosoftResource):
17081710
# Defined to split registry and workspace resource
17091711

17101712
kind: ClassVar[str] = "azure_machine_learning_registry_model_version"

0 commit comments

Comments
 (0)