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

disable auto_update_conda #243

Merged
merged 6 commits into from
Aug 22, 2023
Merged

disable auto_update_conda #243

merged 6 commits into from
Aug 22, 2023

Conversation

szcf-weiya
Copy link
Contributor

@szcf-weiya szcf-weiya commented Jul 9, 2023

The motivations come from #242 and #238, where the error "ResolvePackageNotFound: - conda==23.1.0" is thrown when conda automatically upgrades from 23.1.0 to 23.5.0.

Although I did not quite understand the real logic of the error, one simple workaround is to disable the auto-update of conda, i.e., fix its version.

On the other hand, since the package Conda.jl has already required to install the latest conda release,

Conda.jl/src/Conda.jl

Lines 167 to 179 in fe6c94c

if USE_MINIFORGE
if !(conda_platform in MINIFORGE_PLATFORMS)
error("Unsupported miniforge platform: $(conda_platform)")
else
res = "https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-"
end
else
if !(conda_platform in MINICONDA_PLATFORMS)
error("Unsupported miniconda platform: $(conda_platform)")
else
res = "https://repo.continuum.io/miniconda/Miniconda$(MINICONDA_VERSION)-latest-"
end
end

I think the later update by auto_update_conda is just minor, like from 23.1.0 to 23.5.0, then disabling such minor aggressive updates should be reasonable. As a byproduct, it can save the upgrade time.

@codecov-commenter
Copy link

codecov-commenter commented Jul 9, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.06% 🎉

Comparison is base (79c5487) 87.43% compared to head (fed4dbd) 87.50%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #243      +/-   ##
==========================================
+ Coverage   87.43%   87.50%   +0.06%     
==========================================
  Files           1        1              
  Lines         207      208       +1     
==========================================
+ Hits          181      182       +1     
  Misses         26       26              
Files Changed Coverage Δ
src/Conda.jl 87.50% <100.00%> (+0.06%) ⬆️

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@aplavin
Copy link

aplavin commented Aug 21, 2023

Would be great to have a fix for this issue! Any problems with the PR?
@stevengj @mkitti

@mkitti
Copy link
Member

mkitti commented Aug 21, 2023

Why are the Windows tests failing?

@szcf-weiya
Copy link
Contributor Author

szcf-weiya commented Aug 21, 2023

I think it is just a simple edit, and should not be related to the platform.

How can we rerun the test? (I found a way, just update my forked repo). Because I noticed the near commits also failed on Windows.

image

either .condarc or condarc-julia.yml should work, but it might be more clear to use .condarc in ROOTENV
This reverts commit 49574be.
@szcf-weiya
Copy link
Contributor Author

szcf-weiya commented Aug 21, 2023

Windows failed during the installation of miniconda, so I am guessing (tried to check the documentation https://docs.conda.io/projects/conda/en/latest/user-guide/install/windows.html but failed to find related documentation) whether the error is due to the provided PREFIX folder is not empty since I created the file condarc-julia.yaml in the package building step when (mini)conda was not yet installed.

So the updated version is to write the config file condarc-julia.yaml after installing (mini)conda.

@stevengj
Copy link
Member

LGTM.

@stevengj stevengj merged commit 362d895 into JuliaPy:master Aug 22, 2023
9 checks passed
@aplavin
Copy link

aplavin commented Aug 22, 2023

Hm, I tested half a hour ago, and turns out that the underlying issue was already fixed somehow: PyCall, PyPlot, and other dependent packages install just fine on GitHub Actions. The same action failed just two weeks ago with the ResolvePackageNotFound error.

Not sure what changed, and where...

@stevengj
Copy link
Member

Probably Conda fixed their packages in the meantime? But I still feel like it is good practice not to upgrade unless the user specifically requests Conda.update().

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.

None yet

5 participants