Open bmaitner opened 1 year ago
Hello @bmaitner, thank you for opening this PR.
I very much appreciate your work on implementing non-interactive authentication using rgee. I have a few suggestions to consider:
ee_Initialize
function, I will suggest overloading the existing user
, drive
, and gcs
parameters like this:ee_Initialize(
user="/EE_credential_path",
drive="/JSON_token_path",
gcs="/service_account_key_path"
)
ee_Initialize
function itself, rather than adding the drive_cred_path
argument to ee_as_stars
or ee_as_sf
. This way, all the necessary authentication steps can be performed in one place. To avoid conflicts and ensure a smooth transition (since the version of ee_Initialize
in this PR is not the one currently used by the latest rgee version, and it seems that some arguments are duplicated, i.e. see user and email). I can start a new PR and work together to make this work!Please let me know what you think about these suggestions. Once again, thank you for addressing this important topic and your contributions to the project.
Per #317 I've modified rgee so that it can work in a non-interactive setting using JSON format Google credentials. This seems to be working, as I've been able to use it in workflows for continuous integration via Github actions (see example here: https://github.com/AdamWilsonLab/emma_envdata ).
This PR is more of a "proof of concept". If you're happy with the general approach, I'll clean it up, fix the merge conflicts, etc. If not, I'm happy to take an alternative approach if you have options you prefer.