Skip to content

Commit

Permalink
Merge pull request #65 from kubeflow/main
Browse files Browse the repository at this point in the history
[pull] main from kubeflow:main
  • Loading branch information
openshift-merge-bot[bot] authored May 20, 2024
2 parents 674d429 + 4374347 commit 39ea1a5
Show file tree
Hide file tree
Showing 5 changed files with 215 additions and 297 deletions.
54 changes: 28 additions & 26 deletions clients/python/poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion clients/python/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ hf = ["huggingface-hub"]
sphinx = "^7.2.6"
furo = "^2023.9.10"
myst-parser = { extras = ["linkify"], version = "^2.0.0" }
pytest = "^7.4.2"
pytest = ">=7.4.2,<9.0.0"
coverage = { extras = ["toml"], version = "^7.3.2" }
pytest-cov = "^4.1.0"
sphinx-autobuild = "^2021.3.14"
Expand Down
5 changes: 3 additions & 2 deletions internal/apiutils/api_utils.go
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
package apiutils

import (
"fmt"

"github.com/kubeflow/model-registry/internal/converter"
"github.com/kubeflow/model-registry/internal/ml_metadata/proto"
"github.com/kubeflow/model-registry/pkg/api"
model "github.com/kubeflow/model-registry/pkg/openapi"
)

func BuildListOperationOptions(listOptions api.ListOptions) (*proto.ListOperationOptions, error) {

result := proto.ListOperationOptions{}
if listOptions.PageSize != nil {
result.MaxResultSize = listOptions.PageSize
Expand Down Expand Up @@ -63,7 +64,7 @@ func BuildListOption(pageSize string, orderBy model.OrderByField, sortOrder mode
if pageSize != "" {
conv, err := converter.StringToInt32(pageSize)
if err != nil {
return api.ListOptions{}, err
return api.ListOptions{}, fmt.Errorf("%v: %w", err, api.ErrBadRequest)
}
pageSizeInt32 = &conv
}
Expand Down
Loading

0 comments on commit 39ea1a5

Please sign in to comment.