Skip to content

Commit 5c15233

Browse files
authored
Merge pull request #105 from DataMini/release-please--branches--main--changes--next
release: 3.13.0
2 parents dcdc990 + de40767 commit 5c15233

File tree

13 files changed

+66
-44
lines changed

13 files changed

+66
-44
lines changed

.release-please-manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "3.12.0"
2+
".": "3.13.0"
33
}

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,19 @@
11
# Changelog
22

3+
## 3.13.0 (2025-01-08)
4+
5+
Full Changelog: [v3.12.0...v3.13.0](https://github.com/DataMini/asktable-python/compare/v3.12.0...v3.13.0)
6+
7+
### Features
8+
9+
* **api:** Config update for frei-l/dev ([#106](https://github.com/DataMini/asktable-python/issues/106)) ([65d8b08](https://github.com/DataMini/asktable-python/commit/65d8b08db1483acb19cb7863092dc78a3cceee09))
10+
11+
12+
### Chores
13+
14+
* add missing isclass check ([#104](https://github.com/DataMini/asktable-python/issues/104)) ([10aa4e2](https://github.com/DataMini/asktable-python/commit/10aa4e2574524a5e5efc9b6f77bef9067dae2778))
15+
* **internal:** codegen related update ([#107](https://github.com/DataMini/asktable-python/issues/107)) ([6fc5d90](https://github.com/DataMini/asktable-python/commit/6fc5d9056079a39db002893db247d88942a5da70))
16+
317
## 3.12.0 (2025-01-06)
418

519
Full Changelog: [v3.11.0...v3.12.0](https://github.com/DataMini/asktable-python/compare/v3.11.0...v3.12.0)

api.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ from asktable.types import (
150150
Meta,
151151
DatasourceRetrieveResponse,
152152
DatasourceDeleteResponse,
153-
DatasourceAddFileResponse,
153+
DatasourceAddFilesResponse,
154154
DatasourceDeleteFileResponse,
155155
)
156156
```
@@ -162,7 +162,7 @@ Methods:
162162
- <code title="patch /datasources/{datasource_id}">client.datasources.<a href="./src/asktable/resources/datasources/datasources.py">update</a>(datasource_id, \*\*<a href="src/asktable/types/datasource_update_params.py">params</a>) -> <a href="./src/asktable/types/datasource.py">Datasource</a></code>
163163
- <code title="get /datasources">client.datasources.<a href="./src/asktable/resources/datasources/datasources.py">list</a>(\*\*<a href="src/asktable/types/datasource_list_params.py">params</a>) -> <a href="./src/asktable/types/datasource.py">SyncPage[Datasource]</a></code>
164164
- <code title="delete /datasources/{datasource_id}">client.datasources.<a href="./src/asktable/resources/datasources/datasources.py">delete</a>(datasource_id) -> <a href="./src/asktable/types/datasource_delete_response.py">object</a></code>
165-
- <code title="post /datasources/{datasource_id}/files">client.datasources.<a href="./src/asktable/resources/datasources/datasources.py">add_file</a>(datasource_id, \*\*<a href="src/asktable/types/datasource_add_file_params.py">params</a>) -> <a href="./src/asktable/types/datasource_add_file_response.py">object</a></code>
165+
- <code title="post /datasources/{datasource_id}/files">client.datasources.<a href="./src/asktable/resources/datasources/datasources.py">add_files</a>(datasource_id, \*\*<a href="src/asktable/types/datasource_add_files_params.py">params</a>) -> <a href="./src/asktable/types/datasource_add_files_response.py">object</a></code>
166166
- <code title="delete /datasources/{datasource_id}/files/{file_id}">client.datasources.<a href="./src/asktable/resources/datasources/datasources.py">delete_file</a>(file_id, \*, datasource_id) -> <a href="./src/asktable/types/datasource_delete_file_response.py">object</a></code>
167167

168168
## Meta

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "asktable"
3-
version = "3.12.0"
3+
version = "3.13.0"
44
description = "The official Python library for the asktable API"
55
dynamic = ["readme"]
66
license = "Apache-2.0"
@@ -54,7 +54,7 @@ dev-dependencies = [
5454
"dirty-equals>=0.6.0",
5555
"importlib-metadata>=6.7.0",
5656
"rich>=13.7.1",
57-
"nest_asyncio==1.6.0"
57+
"nest_asyncio==1.6.0",
5858
]
5959

6060
[tool.rye.scripts]

requirements-dev.lock

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ h11==0.14.0
3535
# via httpcore
3636
httpcore==1.0.2
3737
# via httpx
38-
httpx==0.25.2
38+
httpx==0.28.1
3939
# via asktable
4040
# via respx
4141
idna==3.4
@@ -76,7 +76,7 @@ python-dateutil==2.8.2
7676
# via time-machine
7777
pytz==2023.3.post1
7878
# via dirty-equals
79-
respx==0.20.2
79+
respx==0.22.0
8080
rich==13.7.1
8181
ruff==0.6.9
8282
setuptools==68.2.2
@@ -86,7 +86,6 @@ six==1.16.0
8686
sniffio==1.3.0
8787
# via anyio
8888
# via asktable
89-
# via httpx
9089
time-machine==2.9.0
9190
tomli==2.0.2
9291
# via mypy

requirements.lock

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ h11==0.14.0
2525
# via httpcore
2626
httpcore==1.0.2
2727
# via httpx
28-
httpx==0.25.2
28+
httpx==0.28.1
2929
# via asktable
3030
idna==3.4
3131
# via anyio
@@ -37,7 +37,6 @@ pydantic-core==2.27.1
3737
sniffio==1.3.0
3838
# via anyio
3939
# via asktable
40-
# via httpx
4140
typing-extensions==4.12.2
4241
# via anyio
4342
# via asktable

src/asktable/_base_client.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -767,6 +767,9 @@ def __init__(self, **kwargs: Any) -> None:
767767

768768
class SyncHttpxClientWrapper(DefaultHttpxClient):
769769
def __del__(self) -> None:
770+
if self.is_closed:
771+
return
772+
770773
try:
771774
self.close()
772775
except Exception:
@@ -1334,6 +1337,9 @@ def __init__(self, **kwargs: Any) -> None:
13341337

13351338
class AsyncHttpxClientWrapper(DefaultAsyncHttpxClient):
13361339
def __del__(self) -> None:
1340+
if self.is_closed:
1341+
return
1342+
13371343
try:
13381344
# TODO(someday): support non asyncio runtimes here
13391345
asyncio.get_running_loop().create_task(self.aclose())

src/asktable/_models.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -488,7 +488,11 @@ def construct_type(*, value: object, type_: object) -> object:
488488
_, items_type = get_args(type_) # Dict[_, items_type]
489489
return {key: construct_type(value=item, type_=items_type) for key, item in value.items()}
490490

491-
if not is_literal_type(type_) and (issubclass(origin, BaseModel) or issubclass(origin, GenericModel)):
491+
if (
492+
not is_literal_type(type_)
493+
and inspect.isclass(origin)
494+
and (issubclass(origin, BaseModel) or issubclass(origin, GenericModel))
495+
):
492496
if is_list(value):
493497
return [cast(Any, type_).construct(**entry) if is_mapping(entry) else entry for entry in value]
494498

src/asktable/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

33
__title__ = "asktable"
4-
__version__ = "3.12.0" # x-release-please-version
4+
__version__ = "3.13.0" # x-release-please-version

src/asktable/resources/datasources/datasources.py

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
datasource_list_params,
2020
datasource_create_params,
2121
datasource_update_params,
22-
datasource_add_file_params,
22+
datasource_add_files_params,
2323
)
2424
from .indexes import (
2525
IndexesResource,
@@ -347,7 +347,7 @@ def delete(
347347
cast_to=object,
348348
)
349349

350-
def add_file(
350+
def add_files(
351351
self,
352352
datasource_id: str,
353353
*,
@@ -381,7 +381,7 @@ def add_file(
381381
extra_headers = {"Content-Type": "multipart/form-data", **(extra_headers or {})}
382382
return self._post(
383383
f"/datasources/{datasource_id}/files",
384-
body=maybe_transform(body, datasource_add_file_params.DatasourceAddFileParams),
384+
body=maybe_transform(body, datasource_add_files_params.DatasourceAddFilesParams),
385385
files=extracted_files,
386386
options=make_request_options(
387387
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
@@ -713,7 +713,7 @@ async def delete(
713713
cast_to=object,
714714
)
715715

716-
async def add_file(
716+
async def add_files(
717717
self,
718718
datasource_id: str,
719719
*,
@@ -747,7 +747,7 @@ async def add_file(
747747
extra_headers = {"Content-Type": "multipart/form-data", **(extra_headers or {})}
748748
return await self._post(
749749
f"/datasources/{datasource_id}/files",
750-
body=await async_maybe_transform(body, datasource_add_file_params.DatasourceAddFileParams),
750+
body=await async_maybe_transform(body, datasource_add_files_params.DatasourceAddFilesParams),
751751
files=extracted_files,
752752
options=make_request_options(
753753
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
@@ -811,8 +811,8 @@ def __init__(self, datasources: DatasourcesResource) -> None:
811811
self.delete = to_raw_response_wrapper(
812812
datasources.delete,
813813
)
814-
self.add_file = to_raw_response_wrapper(
815-
datasources.add_file,
814+
self.add_files = to_raw_response_wrapper(
815+
datasources.add_files,
816816
)
817817
self.delete_file = to_raw_response_wrapper(
818818
datasources.delete_file,
@@ -850,8 +850,8 @@ def __init__(self, datasources: AsyncDatasourcesResource) -> None:
850850
self.delete = async_to_raw_response_wrapper(
851851
datasources.delete,
852852
)
853-
self.add_file = async_to_raw_response_wrapper(
854-
datasources.add_file,
853+
self.add_files = async_to_raw_response_wrapper(
854+
datasources.add_files,
855855
)
856856
self.delete_file = async_to_raw_response_wrapper(
857857
datasources.delete_file,
@@ -889,8 +889,8 @@ def __init__(self, datasources: DatasourcesResource) -> None:
889889
self.delete = to_streamed_response_wrapper(
890890
datasources.delete,
891891
)
892-
self.add_file = to_streamed_response_wrapper(
893-
datasources.add_file,
892+
self.add_files = to_streamed_response_wrapper(
893+
datasources.add_files,
894894
)
895895
self.delete_file = to_streamed_response_wrapper(
896896
datasources.delete_file,
@@ -928,8 +928,8 @@ def __init__(self, datasources: AsyncDatasourcesResource) -> None:
928928
self.delete = async_to_streamed_response_wrapper(
929929
datasources.delete,
930930
)
931-
self.add_file = async_to_streamed_response_wrapper(
932-
datasources.add_file,
931+
self.add_files = async_to_streamed_response_wrapper(
932+
datasources.add_files,
933933
)
934934
self.delete_file = async_to_streamed_response_wrapper(
935935
datasources.delete_file,

0 commit comments

Comments
 (0)