Test with frozen envs - #849
Conversation
Add get_unified_versions.sh and pin_dev_env_to_unified.py to help generate frozen-base lock files that track E3SM-Unified's resolved dependency versions, narrowing dev-vs-Unified drift as a source of test_images.py ambiguity. - get_unified_versions.sh: sources a Unified load script and captures the resulting environment's package versions (pip list, with an importlib.metadata fallback). - pin_dev_env_to_unified.py: cross-references those versions against a component's dev.yml, sorting each dependency into pinned / forced deviation (dev.yml's own constraint rules out Unified's version) / flagged for manual review (ambiguous exact pins or non-numeric versions) / no Unified match, and writes a resolved dev.yml plus a Markdown report. Stdlib-only, preserves comments/formatting. Update automated_test.rst (Step 2.5) to document this workflow and to note that expected results may come from either Unified or a dev environment.
|
Action items:
|
|
Currently, the relevant diff can be seen here |
|
@forsyth2, I want to make super sure that I understand what the plan is here. If you are temporarily creating two matching dev environments so you can make a comparison, I'm good with that. If you are hoping to create a frozen dev environment that gets manually updated by maintainers, I am deeply opposed. This got us into a downward spiral in the past where zppy and friends tested with very old dependencies, creating nightmares at E3SM-Unified updates. |
@xylar See full discussion at #848. Summary:
Definitely not the idea! My thinking was some sort of cyclical workflow like:
That is, the dependencies should never be more out-of-date than the last E3SM Unified release. So, in practice, nothing should be more than ~6 months out of date. |
|
I understand the tedium of chasing baselines that are a moving target, and I can understand that pinning dependencies is a tempting way to handle that. Please try to see things from my perspective. Exactly this temptation is what causes E3SM-Unified integration to become a nightmare for me. I desperately need you to always be testing with the newest possible versions of all your dependencies, and only constraining them with upper bounds when you know they have broken something and you (or someone else) hasn't fixed it yet. E3SM-Project/e3sm_diags#1075 is an example of that kind of a temporary constraint. So if you can test with a development environment that is as similar as possible to what you used to generate your baselines and test with another environment that has the latest and greatest of everything and be sure it isn't broken, I am good. But if you stop testing the latest dependencies, that's where you create a nightmare for me come October. |
Thanks @xylar for further explaining the concern. I understand now. We can aim for two test runs per week:
Am I understanding correctly that this workflow would be a good compromise for both of us? The hassle of running the test twice should be reduced by the automation being introduced in #774. I should also note this is a bit of a moot point for the immediate future, since @chengzhuzhang noted this should be lower priority nice-to-have item on the discussion thread. |
|
@forsyth2, if that is feasible, it would be amazing from my perspective! |
|
@forsyth2 Just to clarify, the current approach, the tests do use latest conda yaml files based on those from individual repos when testing |
@chengzhuzhang Correct, in my current approach (both manually as during Spring's Unified release AND automated as in #774), I create brand new dev environments using the latest fetched |
|
@forsyth2 Thanks for clarifying, this is good to confirm. I think we’re in a good position, as our testing is based on the latest dependencies that Conda resolves. |
Summary
Objectives:
Issue resolution:
Select one: This pull request is...
Small Change