From 203d344496035328092d990594f536c2f1234b9e Mon Sep 17 00:00:00 2001 From: Lingqing Gan Date: Mon, 24 Feb 2025 11:39:16 -0800 Subject: [PATCH 1/3] test: remove pyarrow prerelease pin The referred upstream issue has been fixed. --- noxfile.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/noxfile.py b/noxfile.py index bf5b3d2..c487cd7 100644 --- a/noxfile.py +++ b/noxfile.py @@ -199,10 +199,7 @@ def prerelease(session, tests_path): "--prefer-binary", "--pre", "--upgrade", - # Limit pyarrow to versions prior to 20.0.0.dev19 to prevent a RuntimeWarning - # during import. This workaround can be removed once the underlying issue - # in pyarrow is resolved (see: https://github.com/apache/arrow/issues/45380). - "pyarrow<=20.0.0.dev18", + "pyarrow", ) # Avoid pandas==2.2.0rc0 as this version causes PyArrow to fail. Once newer # prerelease comes out, this constraint can be removed. See From b649f81803763cbb2c4a66a0375ac67a161be274 Mon Sep 17 00:00:00 2001 From: Linchin Date: Wed, 26 Feb 2025 13:51:13 -0800 Subject: [PATCH 2/3] add kwargs for as_py() --- db_dtypes/json.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/db_dtypes/json.py b/db_dtypes/json.py index 99e0c67..e10c40c 100644 --- a/db_dtypes/json.py +++ b/db_dtypes/json.py @@ -257,8 +257,8 @@ def __array__(self, dtype=None, copy: bool | None = None) -> np.ndarray: class JSONArrowScalar(pa.ExtensionScalar): - def as_py(self): - return JSONArray._deserialize_json(self.value.as_py() if self.value else None) + def as_py(self, **kwargs): + return JSONArray._deserialize_json(self.value.as_py(**kwargs) if self.value else None) class JSONArrowType(pa.ExtensionType): From 0997f6db8518fcb87fe538bc4aac8f4a937244ff Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Wed, 26 Feb 2025 21:53:16 +0000 Subject: [PATCH 3/3] =?UTF-8?q?=F0=9F=A6=89=20Updates=20from=20OwlBot=20po?= =?UTF-8?q?st-processor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --- db_dtypes/json.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/db_dtypes/json.py b/db_dtypes/json.py index e10c40c..835d638 100644 --- a/db_dtypes/json.py +++ b/db_dtypes/json.py @@ -258,7 +258,9 @@ def __array__(self, dtype=None, copy: bool | None = None) -> np.ndarray: class JSONArrowScalar(pa.ExtensionScalar): def as_py(self, **kwargs): - return JSONArray._deserialize_json(self.value.as_py(**kwargs) if self.value else None) + return JSONArray._deserialize_json( + self.value.as_py(**kwargs) if self.value else None + ) class JSONArrowType(pa.ExtensionType):