From 6190419e5967a3cd10bce634182c8b5d3b83bc2e Mon Sep 17 00:00:00 2001 From: coastalwhite Date: Tue, 3 Dec 2024 10:29:50 +0100 Subject: [PATCH] i hate python typechecking with a passion --- .../tests/unit/test_row_encoding_sort.py | 26 ++++++++++--------- 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/py-polars/tests/unit/test_row_encoding_sort.py b/py-polars/tests/unit/test_row_encoding_sort.py index 46aae731e3bd..7e85ccd6ea7c 100644 --- a/py-polars/tests/unit/test_row_encoding_sort.py +++ b/py-polars/tests/unit/test_row_encoding_sort.py @@ -5,7 +5,7 @@ import datetime import decimal import functools -from typing import Any, Literal, Optional +from typing import Any, Literal, Optional, Union import pytest from hypothesis import given @@ -15,17 +15,19 @@ from polars.testing.parametric import column, dataframes, series Element = Optional[ - bool - | int - | float - | str - | decimal.Decimal - | datetime.date - | datetime.datetime - | datetime.time - | datetime.timedelta - | list[Any] - | dict[Any, Any] + Union[ + bool, + int, + float, + str, + decimal.Decimal, + datetime.date, + datetime.datetime, + datetime.time, + datetime.timedelta, + list[Any], + dict[Any, Any], + ] ] OrderSign = Literal[-1, 0, 1]