Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SDK/Components - Improved error when type checking fails in constructor #732

Conversation

Ark-kun
Copy link
Contributor

@Ark-kun Ark-kun commented Jan 24, 2019

/assign @qimingj @gaoning777 @hongye-sun


This change is Reviewable

verify_object_against_type(v, parameter_type)
try:
verify_object_against_type(v, parameter_type)
except Exception as e:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: is there a more specific exception to catch?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On one hand, the exception is likely TypeError. On another hand we're re-throwing the error, so we want to wrap all exceptions. Basically, we just add the parameter name information to the exception.

@hongye-sun
Copy link
Contributor

/lgtm

@Ark-kun
Copy link
Contributor Author

Ark-kun commented Jan 25, 2019

/approve

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Ark-kun

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@Ark-kun
Copy link
Contributor Author

Ark-kun commented Jan 25, 2019

/test kubeflow-pipeline-e2e-test

@k8s-ci-robot k8s-ci-robot merged commit d15c724 into kubeflow:master Jan 25, 2019
@Ark-kun Ark-kun deleted the SDK/Components---Improved-error-when-type-checking-fails-in-constructor branch March 20, 2019 00:37
Linchin pushed a commit to Linchin/pipelines that referenced this pull request Apr 11, 2023
…ubeflow#732)

* Setup a kf-ci-dev namespace for manual sync'ing of Tekton pipelines.

* This namespace is intended to allow for testing of changes to the pipelines
  without having to first check in the changes.

Revert "Update Dockerfile.py3 (kubeflow#729)"
  This commit doesn't build.
This reverts commit 0de5733.

* Fix the entrypoint in Dockerfile.py3 for kubeflow/testing#684
* Rebuild the test worker image

* Fix a bug in kf-ready-task; not properly substituting in KFNAME

* Rehydrate

* Update
magdalenakuhn17 pushed a commit to magdalenakuhn17/pipelines that referenced this pull request Oct 22, 2023
HumairAK pushed a commit to red-hat-data-services/data-science-pipelines that referenced this pull request Mar 11, 2024
… tasks. (kubeflow#732)

* chain nested conditions

* add missing license

* add dependency check to remove unnecessary when expression

* minor improvement to check for the exact condition rather than just the condition task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants