From 7cb3adef86a781ae422c8774a2da7a96313b22ea Mon Sep 17 00:00:00 2001 From: Krzysztof Date: Thu, 16 Feb 2023 02:50:16 +0100 Subject: [PATCH] feat(datafusion): implement ops.Exp --- ibis/backends/datafusion/compiler.py | 1 + ibis/backends/tests/test_numeric.py | 8 +------- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/ibis/backends/datafusion/compiler.py b/ibis/backends/datafusion/compiler.py index 1b09b76065c8..40b8002310cd 100644 --- a/ibis/backends/datafusion/compiler.py +++ b/ibis/backends/datafusion/compiler.py @@ -409,6 +409,7 @@ def negate(op): @translate.register(ops.Cos) @translate.register(ops.Sin) @translate.register(ops.Tan) +@translate.register(ops.Exp) def trig(op): func_name = op.__class__.__name__.lower() func = getattr(df.functions, func_name) diff --git a/ibis/backends/tests/test_numeric.py b/ibis/backends/tests/test_numeric.py index bc3d298a1356..9f3833e73106 100644 --- a/ibis/backends/tests/test_numeric.py +++ b/ibis/backends/tests/test_numeric.py @@ -679,10 +679,7 @@ def test_isnan_isinf( param( L(5.556).exp(), math.exp(5.556), - id='expr', - marks=pytest.mark.notimpl( - ["datafusion"], raises=com.OperationNotDefinedError - ), + id='exp', ), param( L(5.556).sign(), @@ -872,9 +869,6 @@ def test_simple_math_functions_columns( lambda t: t.double_col.add(1).exp(), lambda t: np.exp(t.double_col + 1), id='exp', - marks=pytest.mark.notimpl( - ["datafusion"], raises=com.OperationNotDefinedError - ), ), param( lambda t: t.double_col.add(1).log(2),