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

Retrieve all conda-store environments #2910

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

soapy1
Copy link
Contributor

@soapy1 soapy1 commented Jan 14, 2025

Reference Issues or PRs

Fixes #2599

What does this implement/fix?

Put a x in the boxes that apply

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds a feature)
  • Breaking change (fix or feature that would cause existing features not to work as expected)
  • Documentation Update
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no API changes)
  • Build related changes
  • Other (please describe):

Testing

  • Did you test the pull request locally?
  • Did you add new tests?

How to test this PR?

  1. To test this PR you must have
    a. an installation of Nebari with jhub apps enabled
    b. at least 100 conda-store environments (or decrease the size_limit var in the PR to a sufficiently small number, like 2)
  2. Navigate to the nebari home screen
  3. Click on the deploy app button
  4. Click on the drop down to select the conda store environment for the app
  5. Notice that all the environments are available

Any other comments?

Note, that this API endpoint has the following known bug conda-incubator/conda-store#859.

Users may be able to get around this issue by refreshing the page to get the updated set of environments.

@soapy1
Copy link
Contributor Author

soapy1 commented Jan 14, 2025

I took a look around the code base to find where unit tests for this should go, but I could not find anything obvious. Would love some advice on where a good spot for a test would be. Thanks 🐎

@soapy1 soapy1 marked this pull request as ready for review January 14, 2025 18:13
@viniciusdc
Copy link
Contributor

viniciusdc commented Jan 20, 2025

I was following up on the discussion and had a meeting with Chuck as well; right now, nebari does not have a good architecture to test internal /stages Python code fully; it's basically in another realm than the Nebari package itself. Unless we did something in the direction of explicitly initializing each nested folder as a Python submodule, we can't easily import such methods.

I do like the overall idea and the sound of that, though this might be something to another PR, my suggestion would be to implement the pure method @dcmcand commented above for the URL string list generation and leave there for another PR where we make it possible to be unit-tested.

Regarding the discussion for the default value of PAGE_SIZE_LIMIT, I also agree that this should be overridable somehow; I would prefer this to be configurable somewhere, maybe via trait lets in the future, but right now, just allowing it to be changed by an environment variable might be enough.

@soapy1 soapy1 marked this pull request as draft January 20, 2025 18:58
@soapy1 soapy1 marked this pull request as ready for review January 20, 2025 21:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: New 🚦
Development

Successfully merging this pull request may close these issues.

[BUG] - JHubApps Create App Page Selects only First ~100 Conda Environments
3 participants