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

Problem with cr_setup() - Error in if (file.exists(local_file)) { : argument is of length zero #120

Closed
Camilonfc opened this issue Jun 8, 2021 · 5 comments

Comments

@Camilonfc
Copy link

Hello Mark, I hope you are well.
I write since I am having problems trying to configure the package (googleCloudRun), I was following the configuration video, but from the beginning I have problems. I tried downloading the package from CRAN and your dev version, and I have the same problem, it happens that once the package is installed and I execute the statement library (googleCloudRun)> cr_setup () the configuration menu opens, but when pressing any of The options gives me the following error:
(Error in if (file.exists (local_file)) {: argument is of length zero),
probe uninstalling, restarting RStudio, reinstalling, but the problem continues, I am working with R version 4.1 .0 (2021-05-18).
I would appreciate your help to see what may be happening, since I need to automate my R scripts in GCP.
Greetings!
console log.txt

@MarkEdmondson1234
Copy link
Owner

Could you also run sessionInfo() to show your system? I'm guessing its not finding an .Renviron file in your home directory. You could try creating that. Its a bug though that it fails if it doesn't exist if that is the case.

@MarkEdmondson1234 MarkEdmondson1234 changed the title Problem with cr_setup() Problem with cr_setup() - Error in if (file.exists(local_file)) { : argument is of length zero Jun 8, 2021
@Camilonfc
Copy link
Author

Thanks for your answer, I just checked, leave my information attached, anyway in the work path if I have created a .Renviron file (this was created by watching the video), I don't know if I should leave it in another path or it should go in the project work path.
sessInfo.txt

@Camilonfc
Copy link
Author

I think I found the problem, the .Renviron file in my Home directory was empty, I copied the information from the .Renviron file of my project and it worked, but with another error, but I think it is due to configuration issues.

library (googleCloudRunner)
v Setting scopes to https://www.googleapis.com/auth/cloud-platform
x Failed! Auto-authentication via GCE_AUTH_FILE = C: \xxxxxxxxxxxxxxxx\ GCP Test \ googlecloudrunner-client.json - error was: $ private_key not found in JSON - have you downloaded the correct JSON file?
(Service Account Keys, not service account client)

I will continue with the video, maybe I missed setting a parameter or I made a mistake in something.
Thanks again

@MarkEdmondson1234
Copy link
Owner

Turns it it is an issue with googleAuthR if you don't have an active RStudio project.

@MarkEdmondson1234
Copy link
Owner

Should now be fixed if you use dev version of googleAuthR

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