we have a function where we use a
logger = logging.getLogger() for logging. When we execute the function directly in ONE DATA via Save,Deploy&Run I get a result, where I get all my
logger.info() messages in the
stdout key of the response-json.
However when we trigger the function from within a python processor via SDK with
result: FunctionExecutionResult = onedata_api.functions.execute(id=function_id, arguments=function_arguments)
result.stdout is an empty string.
What could be the issue here?
did you also set
handler = logging.StreamHandler(sys.stdout)
so that your logger streams the output to the stdout?
Alternatively, you can also use
since execution of the same function directly in ONE DATA by clicking a button, this is this case.
We are not setting it directly, but the settings are loaded from the environment in our case.
The only difference is how we execute the function: Execution via the button in ONE DATA works fine, only by execution via SDK the issue appears. I hope the configured environment is also correctly used when executed via SDK?