-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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 - Added ComponentStore search #3884
SDK - Components - Added ComponentStore search #3884
Conversation
ComponentStore(...).search searches for components by name in the configured component store. It prints the name and URL for components that match the given name. Only components on GitHub are currently supported. Example: ``` kfp.components.ComponentStore.default_store.search('xgboost') >>> Xgboost train https://raw.githubusercontent.com/.../components/XGBoost/Train/component.yaml >>> Xgboost predict https://raw.githubusercontent.com/.../components/XGBoost/Predict/component.yaml ```
/retest |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @Ark-kun !
Is that possible to add a test of this library, for example, by either mocking requests.get() or test against current KFP repo?
It would be great to have. I'm experimenting with mocks and plan to add mock-based tests for |
ed2f04a
to
a095a6a
Compare
This is a great idea! |
Currently the search only occurs in the configured repositories. Currently there are some issues with global search (it requires API token and it can only list 1000 results). The repo marker file will make the discovery more reliable, but only when users start adopting it. The
|
/approve |
[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 |
/retest |
4 similar comments
/retest |
/retest |
/retest |
/retest |
Sure. SGTM |
/lgtm |
/retest |
* SDK - Components - Added ComponentStore search ComponentStore(...).search searches for components by name in the configured component store. It prints the name and URL for components that match the given name. Only components on GitHub are currently supported. Example: ``` kfp.components.ComponentStore.default_store.search('xgboost') >>> Xgboost train https://raw.githubusercontent.com/.../components/XGBoost/Train/component.yaml >>> Xgboost predict https://raw.githubusercontent.com/.../components/XGBoost/Predict/component.yaml ``` * Implemented the review feedback * Added retries
* SDK - Components - Added ComponentStore search ComponentStore(...).search searches for components by name in the configured component store. It prints the name and URL for components that match the given name. Only components on GitHub are currently supported. Example: ``` kfp.components.ComponentStore.default_store.search('xgboost') >>> Xgboost train https://raw.githubusercontent.com/.../components/XGBoost/Train/component.yaml >>> Xgboost predict https://raw.githubusercontent.com/.../components/XGBoost/Predict/component.yaml ``` * Implemented the review feedback * Added retries
ComponentStore(...).search searches for components by name in the configured component store. It prints the name and URL for components that match the given name.
Only components on GitHub are currently supported.
Example:
The
default_store
is configured with the main KFP component repo. The users can customize the store with their own repos and URL prefixes: