-
-
Notifications
You must be signed in to change notification settings - Fork 87
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the unexpected behaviour
In version above 0.10, chdb.query() will print error message in stderr.
But it can not redirct or catch into variable.
How to reproduce
import chdb
from io import StringIO
import sys
from contextlib import redirect_stderr
f = StringIO()
with redirect_stderr(f):
res = chdb.query("select 1", "csv")
# sys.stderr.write("write stderr in python")
err = f.getvalue()
print("Capture err by redirect_stderr: ", err)
Expected behavior
Error msg catched and stored into err variable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working