Skip to content

Commit

Permalink
KEP-2170: Generate Python SDK for Kubeflow Training V2 (kubeflow#2310)
Browse files Browse the repository at this point in the history
* Generate SDK models for the Training V2 APIs

Signed-off-by: Andrey Velichkevich <andrey.velichkevich@gmail.com>

* Create pyproject.toml config

Signed-off-by: Andrey Velichkevich <andrey.velichkevich@gmail.com>

* Remove comments

Signed-off-by: Andrey Velichkevich <andrey.velichkevich@gmail.com>

* Fix pre-commit

Signed-off-by: Andrey Velichkevich <andrey.velichkevich@gmail.com>

---------

Signed-off-by: Andrey Velichkevich <andrey.velichkevich@gmail.com>
Signed-off-by: sailesh duddupudi <saileshradar@gmail.com>
  • Loading branch information
andreyvelich authored and saileshd1402 committed Dec 2, 2024
1 parent 4d4d2c8 commit 82d0535
Showing 76 changed files with 8,295 additions and 30 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -42,6 +42,7 @@ examples/.ipynb_checkpoints/

# openapi-codegen tools and auto generated files but useless
hack/python-sdk/openapi-generator-cli.jar
hack/python-sdk-v2/openapi-generator-cli.jar

# Coverage
cover.out
28 changes: 6 additions & 22 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -17,42 +17,26 @@ repos:
rev: 24.2.0
hooks:
- id: black
files: (sdk|examples)/.*
exclude: |
(?x)^(
/*kubeflow_org_v1*|
__init__.py|
api_client.py|
configuration.py|
exceptions.py|
rest.py
)$
- repo: https://github.com/pycqa/flake8
rev: 7.1.1
hooks:
- id: flake8
files: ^(sdk|examples)/.*$
exclude: |
(?x)^(
.*kubeflow_org_v1.*|
__init__\.py|
api_client\.py|
configuration\.py|
exceptions\.py|
rest\.py
)$
exclude: |
(?x)^(
pkg/apis/kubeflow.org/v1/openapi_generated.go|
pkg/apis/kubeflow.org/v1/zz_.*|
pkg/client/.*|
test_job/apis/test_job/v1/.*generated.*.go|
test_job/client/.*|
docs/api/.*|
hack/python-sdk/post_gen.py|
sdk/python/kubeflow/training/[^/]*.py|
sdk/python/kubeflow/training/models/.*|
sdk/python/test/.*|
docs/api/.*|
sdk/python/docs/.*|
sdk/python/.openapi-generator/VERSION|
sdk/python/kubeflow/__init__.py
sdk/python/kubeflow/__init__.py|
sdk_v2/kubeflow/training/[^/]*.py|
sdk_v2/kubeflow/training/models/.*|
sdk_v2/docs/.*
)$
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -51,6 +51,7 @@ generate: controller-gen ## Generate apidoc, sdk and code containing DeepCopy, D
$(CONTROLLER_GEN) object:headerFile="hack/boilerplate/boilerplate.go.txt" paths="./pkg/apis/..."
hack/update-codegen.sh
hack/python-sdk/gen-sdk.sh
hack/python-sdk-v2/gen-sdk.sh
$(MAKE) apidoc

apidoc:
4 changes: 4 additions & 0 deletions api.v2/openapi-spec/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Kubeflow Training V2 OpenAPI Specification

This folder contains an [OpenAPI specification](https://github.com/OAI/OpenAPI-Specification)
for Training V2 API.
Loading

0 comments on commit 82d0535

Please sign in to comment.