From 91910751d701e95820526fb97a7f3f5ad8e0832f Mon Sep 17 00:00:00 2001 From: dangotbanned <125183946+dangotbanned@users.noreply.github.com> Date: Fri, 21 Feb 2025 15:11:59 +0000 Subject: [PATCH] chore(typing): add `CompliantExpr._version` Mentioned in https://discord.com/channels/1235257048170762310/1272835922924273694/1342486928250900570 All impls of the protocol already define this --- narwhals/typing.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/narwhals/typing.py b/narwhals/typing.py index ebd89e7732..4923bbed7b 100644 --- a/narwhals/typing.py +++ b/narwhals/typing.py @@ -25,6 +25,7 @@ from narwhals.expr import Expr from narwhals.series import Series from narwhals.utils import Implementation + from narwhals.utils import Version # All dataframes supported by Narwhals have a # `columns` property. Their similarities don't extend @@ -79,6 +80,7 @@ def aggregate(self, *exprs: Any) -> Self: class CompliantExpr(Protocol, Generic[CompliantSeriesT_co]): _implementation: Implementation _backend_version: tuple[int, ...] + _version: Version _evaluate_output_names: Callable[ [CompliantDataFrame | CompliantLazyFrame], Sequence[str] ]