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

Trouble with rgeeExtra install #4

Open
gltyree opened this issue Dec 21, 2021 · 6 comments
Open

Trouble with rgeeExtra install #4

gltyree opened this issue Dec 21, 2021 · 6 comments

Comments

@gltyree
Copy link

gltyree commented Dec 21, 2021

Hi, I want to use rgeeExtra to import Javascript modules from GEE, as described in r-spatial/rgee issue #155 (r-spatial/rgee#155). I have successfully downloaded the required version of reticulate (1.22.9000) but I am having difficulty downloading the rgeeExtra package. Below is my code and the output.

remotes::install_github("r-earthengine/rgeeExtra")

Downloading GitHub repo r-earthengine/rgeeExtra@HEAD
Error: Failed to install 'rgeeExtra' from GitHub:
Git does not seem to be installed on your system.
In addition: Warning message:
In readLines(file) :
incomplete final line found on 'C:\Users\Gtyree\AppData\Local\Temp\RtmpSSb4xZ\remotesd228626324ba/r-earthengine-rgeeExtra-a14ee7c/.gitmodules'

I attempted to solve the issue by installing Git, but after I did that I began to experience the issue described in r-spatial/rgee issue #91 (r-spatial/rgee#91). It's possible that the problem was unrelated to Git, but was only solved after I both uninstalled Git and ran this code:

library(rgee)
library(reticulate)
earthengine_python <- Sys.getenv("EARTHENGINE_PYTHON", unset = NA)
Sys.setenv(RETICULATE_PYTHON = earthengine_python)
reticulate::py_config()

Is there a way to install rgeeExtra that doesn't require Git? I have also tried devtools::install_github("r-earthengine/rgeeExtra") but received the same error message.

I am using RStudio v. 1.4.1717 on a Windows 10 computer.

@joshualerickson
Copy link

Here to see what happens. Getting the same error.

@csaybar
Copy link
Member

csaybar commented Dec 31, 2021

@joshualerickson @gltyree sorry for the late reply,

PS: rgeeExtra needs reticulate 1.22.9000 to work!
Can you try again? thanks! :)

@joshualerickson
Copy link

Work for me, thanks! Updated to 1.22.9000 and works just fine with the rgeeExtra example.

@gltyree
Copy link
Author

gltyree commented Dec 31, 2021

Hi Cesar, it worked for me this time as well, thank you for the guidance!

As mentioned in my original post, I want to use rgeeExtra to import .js modules, as discussed in r-spatial/rgee#155. Running an rgee equivalent to var X = require(moduleX) presented this error, in which R misinterpreted the require function:

Model = require('users/gtyreegee/MODIS:Modules/CW16_v3_module')

Loading required package: users/gtyreegee/MODIS:Modules/CW16_v3_module
Warning message:
In library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, :
there is no package called ‘users/gtyreegee/MODIS:Modules/CW16_v3_module’

Do you have any guidance on importing .js modules with rgeeExtra?

@gltyree
Copy link
Author

gltyree commented Dec 31, 2021

Disregard that last post - I found the ee_module.R script on the rgeeExtra Github page. Will begin a new issue if one crops up. Thanks again!

@csaybar
Copy link
Member

csaybar commented Jan 2, 2022

:) 👍

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

3 participants