Skip to content

Commit 82d2f18

Browse files
committed
Remove builtins use
1 parent 35510a3 commit 82d2f18

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

python/datafusion/functions.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1259,14 +1259,12 @@ def pi() -> Expr:
12591259
Examples:
12601260
>>> ctx = dfn.SessionContext()
12611261
>>> df = ctx.from_pydict({"a": [1]})
1262-
>>> import builtins
1262+
>>> from math import pi
12631263
>>> result = df.select(
12641264
... dfn.functions.pi().alias("pi")
12651265
... )
1266-
>>> builtins.round(
1267-
... result.collect_column("pi")[0].as_py(), 5
1268-
... )
1269-
3.14159
1266+
>>> result.collect_column("pi")[0].as_py() == pi
1267+
True
12701268
"""
12711269
return Expr(f.pi())
12721270

0 commit comments

Comments
 (0)