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

Error: package or namespace load failed for ‘Seurat’: object ‘markvario’ is not exported by 'namespace:spatstat' #4226

Closed
star0044 opened this issue Mar 15, 2021 · 18 comments · Fixed by #4247

Comments

@star0044
Copy link

I recently installed Seurat 4.0 along with R 4.0.4 on my Macbook Pro running OSX Big Sur v11.1.

I was able to load the Library(Seurat) and run multiple analyses.
It worked well until I installed the "limma" package to speed up the find clusters, and I selected "Yes" when it asked, Do you want to install from sources the package which needs compilation? (Yes/no/cancel)

Now I get the following error message when I try to load the Library(Seurat)

Error: package or namespace load failed for ‘Seurat’:
object ‘markvario’ is not exported by 'namespace:spatstat'

I uninstalled R and re-installed and I re-installed R studio and re-installed Seurat and re-installed limma, but I'm still getting the error.

How can I fix this?

@kalmSveta
Copy link

I have a similar issue:
At first I was getting this error while installation of Seurat. But then I installed earlier version of spatstat. Th installation of Seurat finished successfully after that. But calling library(Seurat) provokes the same error now

@rekren
Copy link

rekren commented Mar 15, 2021

I have faced with the same issue, too.
Downgrading the spatstat package or re-installing Seurat didn't work in my case, too.
Looking for a way the fix this issue.

@lldelisle
Copy link
Contributor

Hi,
I got the same issue. spatstat just changed its package structure: spatstat::markvario become spatstat.core::markvario.
I also noticed that:

remove.packages(grep("spatstat", installed.packages(), value = T))
.rs.restartR()
devtools::install_version("spatstat", version = "1.64-1")

Solved the issue.

@stela2502
Copy link

AGH - had the same problem and also thought about installing from github, but then used 1.64-2 which obviously is the broken one. Thank you!

@star0044
Copy link
Author

Thanks for the help,
The solution suggested by Ildeslisle also solved my problem

remove.packages(grep("spatstat", installed.packages(), value = T))
.rs.restartR()
devtools::install_version("spatstat", version = "1.64-1")

Just a note, need to also be sure spatstat doesn't get automatically updated when installing other packages like SingleR and Scater

@zijianni
Copy link

Bioconductor sent me an email saying my package (depending on Seurat) was unable to build or install, and the error is exactly the same here and has been reported at #4222

@kokitsuyuzaki
Copy link

I got the same issue.
My Bioconductor packages scTensor and scTGIF cannot be built with the error message below.

Error: package or namespace load failed for ‘Seurat’:
 object ‘markvario’ is not exported by 'namespace:spatstat'
Error: package ‘Seurat’ could not be loaded
Execution halted

@stela2502
Copy link

The spatstat people answered this:

"I'm sorry, but this is not a bug. The function has been moved to a sub package and the maintainer of Seurat has been informed and needs to update the package. The error will go away when this is done. Did you report the error to the maintainer?"

I have copied this answer here to finish up this discussion with as much info as I have.

Looking forward to the Seurat fix.

@vd4mmind
Copy link

I still have not been able to solve this. Tried to downgrade statspat but that did not help. I am on the Rstudio server and tried to create a new .libPaths() so as to install the downgraded package in a specific location and run it in my project followed by Seurat install and library load but that did not solve the issue. Unsure at this moment it's better to wait for Seurat maintainers to push their changes and wait or is there some other workaround that I might not be knowing?

@mojaveazure
Copy link
Member

Hi all,

We are aware of this issue and working on submitting a fix to CRAN. In the meantime, this issue has been resolved on the develop branch of Seurat. To install the development version of Seurat, please see the instructions here.

@demomwu
Copy link

demomwu commented Mar 17, 2021

Hi,
I got the same issue. spatstat just changed its package structure: spatstat::markvario become spatstat.core::markvario.
I also noticed that:

remove.packages(grep("spatstat", installed.packages(), value = T))
.rs.restartR()
devtools::install_version("spatstat", version = "1.64-1")

Solved the issue.

excuse me ,i wonder how to "changed its package structure: spatstat::markvario become spatstat.core::markvario"?

@apelonero-GladstoneInstitutes
Copy link

Hi all,

We are aware of this issue and working on submitting a fix to CRAN. In the meantime, this issue has been resolved on the develop branch of Seurat. To install the development version of Seurat, please see the instructions here.

Thanks! Dev version fixed this for me. Out of curiosity, what is the go-to recommendation here? I see two solutions (as of today, prior to the CRAN update):

  1. reinstall previous working version of spatstat as star0044 suggested:
    remove.packages(grep("spatstat", installed.packages(), value = T))
    .rs.restartR()
    devtools::install_version("spatstat", version = "1.64-1")
  2. install the latest dev release of Seurat (instructions here)

I ask since I know a few folks who kind of insist on running CRAN-flavored Seurat. Wondering what to tell them should they ask for some help 👍

@andrewwbutler
Copy link
Collaborator

Hi everyone,

An updated version (4.0.1) of Seurat is now available on CRAN and should resolve this issue. If you were having trouble installing previously, please try again with install.packages("Seurat").

@skashin
Copy link

skashin commented Apr 1, 2021

Hi Andrew

Will you be able to submit a fix for the Seurat v3.2.3 to CRAN as well?

Thanks,
Seva

@andrewwbutler
Copy link
Collaborator

Hi Seva,

If you want to run Seurat v3.2.3, you will need to install the older version of spatstat as described in the thread above.

@skashin
Copy link

skashin commented Apr 1, 2021 via email

@mojaveazure
Copy link
Member

CRAN's policies prevent us from changing already-released versions. Moreover, CRAN does not allow pegging dependency versions to specific versions. The only management of dependencies we have is specifying minimum versions as R/CRAN has adopted a forward-looking model for dependency resolution (we have to be compatible with the latest-released version of each of our dependencies, and in some cases must be compatible with the development version as well).

If you wish to use an older version of Seurat, you will have to make sure that the versions of Seurat's dependencies you use are compatible with the version of Seurat you use. We unfortunately cannot provide more assistance than that.

@skashin
Copy link

skashin commented Apr 1, 2021 via email

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 a pull request may close this issue.