I am trying to execute a .py file from a .gd script with the following code:
var global_dir_path = ProjectSettings.globalize_path("res://OAuth2.0")
var ERR = OS.execute("python", [global_dir_path + "/get_credentials.py"], true)
if ERR == OK:
push_error("ERROR EXECUTING 'get_credentials.py' WITH ERROR CODE: %s"%ERR)
I am getting an ERR == 1, which is "FAILED = 1 --- Generic error" from the Godot Docs.
I know for a fact that the script works when run from my IDE and the command line, and that the path to the .py script is correct. I am wondering if there are some permissions I am violating or something?
The .py script accesses scripts in its local directory. do you think that is the issue somehow?