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

pak fails to update curl on Debian-based systems #691

Closed
Robinlovelace opened this issue Sep 20, 2024 · 4 comments
Closed

pak fails to update curl on Debian-based systems #691

Robinlovelace opened this issue Sep 20, 2024 · 4 comments

Comments

@Robinlovelace
Copy link

We're working on a container that contained the following:

pak::pkg_install("geocompx/geocompkg", dependencies = TRUE)

For some reason, it failed to install curl, as shown here and in subsequent error message: https://github.com/geocompx/docker/actions/runs/10944692306/job/30387186965#step:8:233

#11 9.439 + curl              5.2.1  > 5.2.2       [bld][cmp][dl] (716.70 kB) + x libcurl4-openssl-dev, x libssl-dev
...
 #11 159.8 --------------------------- [ANTICONF] --------------------------------
#11 159.8 Configuration failed because libcurl was not found. Try installing:
#11 159.8  * deb: libcurl4-openssl-dev (Debian, Ubuntu, etc)

Wondering if it's something to do with the fact we're using pixi to install R here, but thought these unexpected error messages may be of use.

More confusing is that, as far as I can tell, the error persists after asking pak not to upgrade anything:

pak::pkg_install("geocompx/geocompkg", dependencies = TRUE, upgrade = FALSE)

I get the same error message after that.

@Robinlovelace
Copy link
Author

As shown here, pak still tries to upgrade the package even with the upgrade arg set to FALSE: https://github.com/geocompx/docker/actions/runs/10953278326/job/30413287861#step:8:368

@Robinlovelace
Copy link
Author

After switching from exactly the same command with remotes it worked so this looks like a bug to me:

remotes::install_github("geocompx/geocompkg", dependencies = TRUE, upgrade = FALSE)

See geocompx/docker@d79080f#diff-1c8aec6e5624030890094bb61ae09a11a1fa1d3bfa85e6313d1d79aa11742468R13

@gaborcsardi
Copy link
Member

This is not a bug in pak, but an interaction with conda. If you are building non-conda R packages with an active conda, the build can fail. Even loading them can fail. Deactivate conda while you are using non-conda R, especially when you are installing packages.

As shown here, pak still tries to upgrade the package even with the upgrade arg set to FALSE:

Because httr2 requires a newer version of curl.

After switching from exactly the same command with remotes it worked so this looks like a bug to me:

Probably because remotes is not very smart, so just ignores the versioned requirements.

@Robinlovelace
Copy link
Author

Because httr2 requires a newer version of curl.

Ah OK makes sense now.

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

No branches or pull requests

2 participants