finally found a way to catch stdout/stderr and any other stream from the embedded python.