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

BUG: pak wants to upgrade a package contrary to what the default setting of what upgrade says #533

Closed
gdevenyi opened this issue Aug 30, 2023 · 4 comments

Comments

@gdevenyi
Copy link

Trying to install this package:
https://github.com/kdzimm/hierarchicell/blob/master/DESCRIPTION

pak::pkg_install("kdzimm/hierarchicell")
! Using bundled GitHub PAT. Please add your own PAT using `gitcreds::gitcreds_set()`.Loading metadata database ... doneWill install 1 package.Will update 1 package.All 2 packages (714.17 kB) are cached.
+ curl          4.3.35.0.2 [bld][cmp] +libcurl4-openssl-dev, ✔ libssl-dev
+ hierarchicell         1.0.0 [bld][cmp] (GitHub: 183ef08)
→ Will install 3 system packages:
+ libglpk-dev  - igraph          
+ libgmp3-dev  - igraph          
+ pandoc       - knitr, rmarkdown

I don't expect curl to be upgraded, as no explicit version is mentioned in DESCRIPTION of the other package, and the default for pkg_install is upgrade=FALSE

@gdevenyi gdevenyi changed the title BUG: pak wants to upgrade a package contrary to what the default setting of upgrade says BUG: pak wants to upgrade a package contrary to what the default setting of what upgrade says Aug 30, 2023
@gdevenyi
Copy link
Author

pak documentation says:

Usage:

     pkg_install(
       pkg,
       lib = .libPaths()[[1L]],
       upgrade = FALSE,
       ask = interactive(),
       dependencies = NA
     )
     

 upgrade: When ‘FALSE’, the default, pak does the minimum amount of
          work to give you the latest version(s) of ‘pkg’. It will only
          upgrade dependent packages if ‘pkg’, or one of their
          dependencies explicitly require a higher version than what
          you currently have. It will also prefer a binary package over
          to source package, even it the binary package is older.

          When ‘upgrade = TRUE’, pak will ensure that you have the
          latest version(s) of ‘pkg’ and all their dependencies.

@gaborcsardi
Copy link
Member

hierarchicell -> Seurat -> httr -> curl

and the latest version of httr requires a curl update:

Imports: curl (>= 5.0.2), jsonlite, mime, openssl (>= 0.8), R6

@gdevenyi
Copy link
Author

How can this be the case when Seurat is already installed and not being upgraded?

@gaborcsardi
Copy link
Member

gaborcsardi commented Aug 31, 2023

It is through some other dependency path then, maybe plotly needs newer httr, which needs newer curl:

❯ pak::pkg_deps_explain("kdzimm/hierarchicell", "curl")
hierarchicell -> Seurat -> httr -> curl
hierarchicell -> Seurat -> plotly -> httr -> curl
hierarchicell -> sva -> genefilter -> AnnotationDbi -> KEGGREST -> httr
  -> curl
hierarchicell -> sva -> genefilter -> annotate -> AnnotationDbi ->
  KEGGREST -> httr -> curl
hierarchicell -> sva -> genefilter -> annotate -> httr -> curl

It is also possible, that while the dependencies are installed, they are broken and do not satisfy their version requirements.

In any case, I can't see your system, so this is guessing game for me, unless you show me the package versions of the whole dependency tree of the package you are installing.

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