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

✨ Enable Arg Parsing in Xircuits Entry Point #149

Merged
merged 9 commits into from
Apr 13, 2022

Conversation

MFA-X-AI
Copy link
Member

@MFA-X-AI MFA-X-AI commented Apr 12, 2022

Description

This PR enables passing arguments from the xircuits console entry point. I've applied it so that we can pull xai_components, examples and datasets from branches.

The two things you can do now is:

  1. xircuits --branch branchName to pull xai-components
  2. xircuits-examples --branch branchName to pull examples and datasets

from your specified branch name. I've also added error handling for file pulling and invalid branches.

References

#131 #132

Pull Request Type

  • Xircuits Core (Jupyterlab Related changes)
  • Xircuits Canvas (Custom RD Related changes)
  • Xircuits Component Library
  • Testing Automation
  • Documentation
  • Others (Please Specify)

Type of Change

  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Tests

The branch fahreza/component-submodules can be used to test differences between master and branch.

1. Test Entry Point

  1. Download wheel from latest github action
  2. Launch xircuits with xircuits --branch fahreza/component-submodules, accept to download xai_components when prompted
  3. Verify that pycaret and modelstash components do not exist

2. Test Example Downloading

  1. Download examples with xircuits-examples --branch fahreza/component-submodules
  2. Verify that AutoML and MS xircuits examples do not exist

3. Test Exception Handling

  1. Try xircuits --branch or xircuits-examples --branch with an invalid branch name
  2. Verify that it returns examples from XpressAi/Xircuits branch invalidBranch does not exist!

Tested on?

  • Windows
  • Linux Ubuntu
  • Centos
  • Mac
  • Others (State here -> xxx )

Notes

  1. I've lowercased the Datasets directory to match the rest of the repository.
  2. The submodules are treated as files instead of dir in pygithub and will return a invalid file message. Nonetheless, the rest of the components will be downloaded.

@MFA-X-AI MFA-X-AI changed the title ✨ Enable Download Components from Branch ✨ Enable Arg Parsing in Xircuits Entry Point Apr 13, 2022
@MFA-X-AI MFA-X-AI marked this pull request as ready for review April 13, 2022 05:30
@MFA-X-AI MFA-X-AI requested a review from mansouralawi April 13, 2022 06:12
Copy link
Member

@mansouralawi mansouralawi left a comment

Choose a reason for hiding this comment

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

Thank you for the PR.

Passed tests

  • Download components
  1. xircuits --branch fahreza/component-submodules No pycaret or modelstash components but it launched Xircuits (expected)
  • Download examples
  1. xircuits-examples --branch fahreza/component-submodules No AutoML examples
  2. xircuits-examples --branch invalid_branch_name returned the error message

Failed test

  • Download components
  1. xircuits --branch invalid_branch_name No error message and launched Xircuits

Suggested improvement

  • To introduce xircuits-components similarly to xircuits-examples to download components.

image

@MFA-X-AI
Copy link
Member Author

xircuits --branch invalid_branch_name No error message and launched Xircuits

Oh, for this one you'd need to delete the xai_component folder first since it performs a folder check on start. That does remind me, maybe we can add an entry point just to download the xai_components.

@mansouralawi
Copy link
Member

When deleting the xai_component folder and running xircuits --branch invalid_branch_name it returned the error and then launched Xircuits. (expected)

An additional entry point specific for xai_components download is a good idea.

@MFA-X-AI
Copy link
Member Author

Cool. I'll add it to the next "call submodules from entry" PR. :D

@mansouralawi mansouralawi merged commit 8ef5b78 into master Apr 13, 2022
@mansouralawi mansouralawi deleted the fahreza/pull-from-branch branch April 13, 2022 07:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants