Skip to content
This repository has been archived by the owner on Sep 21, 2023. It is now read-only.

demoApp failing to build on MacOS #310

Open
jokroese opened this issue Jun 17, 2020 · 7 comments
Open

demoApp failing to build on MacOS #310

jokroese opened this issue Jun 17, 2020 · 7 comments

Comments

@jokroese
Copy link

Summary

I am trying to run the code described in the Create an app from a package on Github tutorial. As I am using MacOS, I have added the mac_url argument to the electrify function with a link to the desired R build, as described in #272. However, this leads to an error.

Steps to reproduce

MacOS Catalina (10.15.4), R version 4.0.0.

library(electricShine)

buildPath <- tempdir()

electricShine::electrify(app_name = "My_App",
                         short_description = "My demo application",
                         semantic_version = "1.0.0",
                         build_path = buildPath,
                         function_name = "run_app",
                         git_host = "github",
                         git_repo = "chasemc/demoApp@8426481",
                         package_install_opts = list(type = "binary",
                                                     dependencies = c("Depends", 
                                                                      "Imports")
                         ),
                         cran_like_url = "https://cran.r-project.org",
                         mac_url = "https://mac.r-project.org/high-sierra/R-4.0-branch/x86_64/R-4.0-branch.tar.gz"
)

Gives an error:

Error: (converted from warning) package ‘datasets’ in options("defaultPackages") was not found
Execution halted
Error: Failed to install 'demoApp' from GitHub:
  (converted from warning) installation of package ‘/var/folders/16/vnr99r9578572b4ch8zgtl8h0000gn/T//Rtmp2RYFpX/file85852e311c21/demoApp_1.0.18.tar.gz’ had non-zero exit status
Execution halted
Finshed: Installing your Shiny package into electricShine framework
Error in system.file("extdata", "icon", package = my_package_name, lib.loc = library_path) : 
  'package' must be of length 1

Question

Are you able to spot the problem? I suspect that I have incorrectly written something in the electrify function.

@chasemc
Copy link
Owner

chasemc commented Jun 20, 2020

I've run {electricShine} on both WIndows and Linux recently so I'm leaning towards this being a Mac problem and not an {electricShine} problem.

I won't have access to a Mac/dedicated-time for this for a couple months so I can't currently try to find the root cause but I've heard there's been a lot of issue with permissions in the newest Mac OS versions (Catalina).

It likely has to do with this:
https://cran.r-project.org/doc/manuals/r-patched/R-admin.html#Note-for-Catalina-users

@hrbrmstr I know we don't know each other, but you seem like someone who would be interested in seeing what seems like an issue between Mac Catalina and R

@chasemc
Copy link
Owner

chasemc commented Jun 20, 2020

I'll add that as I'm someone about to move back to Mac after a long hiatus this is concerning and has my attention

@hrbrmstr
Copy link

I kinda detest Electron apps for a host of security, usability, power-consumption, and other issues, but lemme see what might be going on.

@hrbrmstr
Copy link

may be a couple days. on vacation and I've got some things in my R profile that break this much earlier in the process (FWIW the build processes shld prbly add in --vanilla whenever they call R or Rscript).

@chasemc
Copy link
Owner

chasemc commented Jun 20, 2020

I had a little time this morning, but still don't have access to Catalina. I ran the demo code through R 4.0.1 on a fresh Windows 10 image and it worked.

There are some modifications I had to do to make R portable on Mac 1 2 so this isn't a pure-installation. However, it does seem like something has changed R-side or Mac side, and it'll take some digging on my part.

@hrbrmstr - I knew Rscript had the vanilla flag, and had overlooked that, but I didn't realize that R or Rterm had it. I've made a PR to fix that. Also, no need to reply during your vacation, go enjoy it.

@drchriscole
Copy link

Any update on this issue? It's still happening on Catalina and R 4.0.4.

@chasemc
Copy link
Owner

chasemc commented Apr 4, 2021

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants