Suddenly there is no package called ‘httr’ - trying to use seurat

This issue has only started today, infuriatingly, this morning all my libraries in my RStudio ran without issue. Im trying to run the package Seurat, which up until now has not been a problem on this machine, using the exact same code.

library (Seurat)
Error: package or namespace load failed for ‘Seurat’ in loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]): there is no package called ‘httr’

When I try to install httr I get the following:

Warning in install.packages :
  installation of package ‘httr’ had non-zero exit status

The downloaded source packages are in
    ‘/private/var/folders/t3/fr59bpbs2237pzbbg04sy3280000gn/T/RtmpkJ97Mc/downloaded_packages’

I am running R version 4.2.1 (2022-06-23) -- "Funny-Looking Kid" on MacOS Monterey version 12.4.
Not a clue why this has started now,

Any pointers welcome, thanks for your time,
Katy

Apologies I missed a good chunk of the error here:

I try install.packages("httr") and get the following

There is a binary version available but the source version is later:
     binary source needs_compilation
httr  1.4.5  1.4.6             FALSE

installing the source package ‘httr’

trying URL 'https://cran.rstudio.com/src/contrib/httr_1.4.6.tar.gz'
Content type 'application/x-gzip' length 157621 bytes (153 KB)
==================================================
downloaded 153 KB

/Library/Frameworks/R.framework/Resources/bin/Rcmd: line 40: sed: command not found
export BIBINPUTS=".:/Library/Frameworks/R.framework/Resources/share/texmf/bibtex/bib:"
export BSTINPUTS=".:/Library/Frameworks/R.framework/Resources/share/texmf/bibtex/bst:"
export CLICOLOR_FORCE="1"
export COMMAND_MODE="unix2003"
export DISPLAY="/private/tmp/com.apple.launchd.mvl13grjQD/org.xquartz:0"
export EDITOR="vi"
export GIT_ASKPASS="rpostback-askpass"
export HOME="/Users/kj15161"
export LANG="en_US.UTF-8"
export LC_CTYPE="en_US.UTF-8"
export LN_S="ln -s"
export LOGNAME="kj15161"
export MAKE="make"
export MPLENGINE="tkAgg"
export OLDPWD
export PAGER="/usr/bin/less"
export PATH="/opt/anaconda3/bin/python"
export PWD="/Users/kj15161/Desktop/Moxon_May"
export PYTHONIOENCODING="utf-8"
export RMARKDOWN_MATHJAX_PATH="/Applications/RStudio.app/Contents/Resources/resources/mathjax-27"
export RSTUDIO="1"
export RSTUDIO_CLI_HYPERLINKS="true"
export RSTUDIO_CONSOLE_COLOR="256"
export RSTUDIO_CONSOLE_WIDTH="134"
export RSTUDIO_FALLBACK_LIBRARY_PATH="/var/folders/t3/fr59bpbs2237pzbbg04sy3280000gn/T/rstudio-fallback-library-path-ROntal"
export RSTUDIO_PANDOC="/Applications/RStudio.app/Contents/MacOS/quarto/bin/tools"
export RSTUDIO_PROGRAM_MODE="desktop"
export RSTUDIO_SESSION_PID="1942"
export RSTUDIO_SESSION_PORT="57704"
export RSTUDIO_USER_IDENTITY="kj15161"
export RSTUDIO_WINUTILS="bin/winutils"
export RS_PPM_FD_READ="8"
export RS_PPM_FD_WRITE="9"
export RS_RPOSTBACK_PATH="/Applications/RStudio.app/Contents/rpostback"
export RS_SHARED_SECRET="b4fcbe4f-ba30-453b-b170-ecd69eb0db06"
export R_ARCH=""
export R_BROWSER="/usr/bin/open"
export R_BZIPCMD="/usr/bin/bzip2"
export R_CLI_HAS_HYPERLINK_IDE_HELP="true"
export R_CLI_HAS_HYPERLINK_IDE_RUN="true"
export R_CLI_HAS_HYPERLINK_IDE_VIGNETTE="true"
export R_CMD="/Library/Frameworks/R.framework/Resources/bin/Rcmd"
export R_DOC_DIR="/Library/Frameworks/R.framework/Resources/doc"
export R_GZIPCMD="/usr/bin/gzip"
export R_HOME="/Library/Frameworks/R.framework/Resources"
export R_INCLUDE_DIR="/Library/Frameworks/R.framework/Resources/include"
export R_LIBS="/Library/Frameworks/R.framework/Versions/4.2/Resources/library"
export R_LIBS_SITE="/Library/Frameworks/R.framework/Resources/site-library"
export R_LIBS_USER="/Users/kj15161/Library/R/x86_64/4.2/library"
export R_MAX_VSIZE="100GB"
export R_OSTYPE="unix"
export R_PAPERSIZE="a4"
export R_PDFVIEWER="/usr/bin/open"
export R_PLATFORM="x86_64-apple-darwin17.0"
export R_PRINTCMD="lpr"
export R_QPDF="/Library/Frameworks/R.framework/Resources/bin/qpdf"
export R_RD4PDF="times,inconsolata,hyper"
export R_SESSION_TMPDIR="/var/folders/t3/fr59bpbs2237pzbbg04sy3280000gn/T//RtmpJQDUIt"
export R_SHARE_DIR="/Library/Frameworks/R.framework/Resources/share"
export R_STRIP_SHARED_LIB="strip -x"
export R_STRIP_STATIC_LIB="strip -S"
export R_SYSTEM_ABI="macos,gcc,gxx,gfortran,gfortran"
export R_TEXI2DVICMD="/usr/local/bin/texi2dvi"
export R_UNZIPCMD="/usr/bin/unzip"
export R_VERSION="4.2.1"
export R_ZIPCMD="/usr/bin/zip"
export SED="/usr/bin/sed"
export SHELL="/bin/zsh"
export SHLVL="2"
export SSH_ASKPASS="rpostback-askpass"
export SSH_AUTH_SOCK="/private/tmp/com.apple.launchd.HWkivOZQaV/Listeners"
export TAR="/usr/bin/tar"
export TERM="xterm-256color"
export TEXINPUTS=".:/Library/Frameworks/R.framework/Resources/share/texmf/tex/latex:"
export TMPDIR="/var/folders/t3/fr59bpbs2237pzbbg04sy3280000gn/T/"
export TZDIR="/var/db/timezone/zoneinfo"
export USER="kj15161"
export XPC_FLAGS="0x0"
export XPC_SERVICE_NAME="application.org.rstudio.RStudio.13546952.13546972"
export __CFBundleIdentifier="org.rstudio.RStudio"
export __CF_USER_TEXT_ENCODING="0x1F5:0x0:0x0"
* installing *source* package ‘httr’ ...
** package ‘httr’ successfully unpacked and MD5 sums checked
** using staged installation
** R
** demo
** inst
** byte-compile and prepare package for lazy loading
sh: rm: command not found
** help
*** installing help indices
** building package indices
sh: rm: command not found
** installing vignettes
** testing if installed package can be loaded from temporary location
sh: rm: command not found
sh: mv: command not found
Warning in system(paste("mv -f", shQuote(instdir), shQuote(dirname(final_instdir)))) :
  error in running command
ERROR:   moving to final location failed
sh: rm: command not found
Warning in install.packages :
  installation of package ‘httr’ had non-zero exit status

The downloaded source packages are in
    ‘/private/var/folders/t3/fr59bpbs2237pzbbg04sy3280000gn/T/RtmpkJ97Mc/downloaded_packages’

The error messages

and

indicate a misconfigured $PATH$ in the env under which the RStudio app is running. Depending on the level of expertise of the end user, this can be difficult to fix remotely by walking through the steps. If you have an in-person resource that would be easier and quicker.

Thanks for your help! I have no in-person resource sadly, but i'd be keen to give it a go if you'd be happy to share some pointers?

Let's take this offline, since there may be a lot of back and forth. I'll send you a DM and we can report back to the community when we've sorted this.

Really appreciate it technocrat, thanks again!

This topic was automatically closed 42 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.