Commits


Will Jones authored and Antoine Pitrou committed 8113c37fb43
ARROW-11342: [Python] [Gandiva] Expose ToString and result type information These methods are intended to make it easier to work with and debug the Gandiva expression builder. ```python import pyarrow import pyarrow.gandiva as gandiva builder = gandiva.TreeExprBuilder() lit = builder.make_literal(1000.0, pyarrow.float64()) print(lit) # Before: <pyarrow.gandiva.Node object at 0x7f36fd37ecf0> # After: (const double) 1000 raw(408f400000000000) field = builder.make_field(pyarrow.field('a', pyarrow.float64())) print(field) # Before: <pyarrow.gandiva.Node object at 0x7ff7daf99f90> # After: (double) a print(builder.make_function('greater_than', [field, lit], pyarrow.bool_())) # Before: <pyarrow.gandiva.Node object at 0x7ff7d24bde70> # After: bool greater_than((double) a, (const double) 1000 raw(408f400000000000)) ``` Closes #9288 from wjones127/ARROW-11342/gandiva-repr Lead-authored-by: Will Jones <will.jones@mscience.com> Co-authored-by: Will Jones <willjones127@gmail.com> Signed-off-by: Antoine Pitrou <antoine@python.org>