FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

fix: type scalar UDF returns as Arrow arrays by BharatDeva · Pull Request #1528 · apache/datafusion-python · GitHub

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension .py  (1) All 1 file type selected
Viewed files
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Unified
Split
Hide whitespace
Diff view
Unified
Split
Hide whitespace
6 changes: 3 additions & 3 deletions python/datafusion/user_defined.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
if TYPE_CHECKING:
from _typeshed import CapsuleType as _PyCapsule

_R = TypeVar("_R", bound=pa.DataType)
_R = TypeVar("_R", bound=pa.Array)
from collections.abc import Callable, Sequence


Expand Down Expand Up @@ -125,7 +125,7 @@ def __init__(
name: str,
func: Callable[..., _R],
input_fields: list[pa.Field],
return_field: _R,
return_field: pa.Field,
volatility: Volatility | str,
) -> None:
"""Instantiate a scalar user-defined function (UDF).
Expand Down Expand Up @@ -264,7 +264,7 @@ def _function(

def _decorator(
input_fields: Sequence[pa.DataType | pa.Field] | pa.DataType | pa.Field,
return_field: _R,
return_field: pa.DataType | pa.Field,
volatility: Volatility | str,
name: str | None = None,
) -> Callable:
Expand Down
Loading

Back | FazBrowse Home | New Git URL