meilisearch-python-sdk 3.5.1__tar.gz → 3.6.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of meilisearch-python-sdk might be problematic. Click here for more details.
- meilisearch_python_sdk-3.5.1/.github/workflows/pypi_publish.yaml → meilisearch_python_sdk-3.6.1/.github/workflows/docs_publish.yml +4 -9
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/.github/workflows/nightly_testing.yml +3 -12
- meilisearch_python_sdk-3.6.1/.github/workflows/pypi_publish.yml +29 -0
- meilisearch_python_sdk-3.5.1/.github/workflows/testing.yaml → meilisearch_python_sdk-3.6.1/.github/workflows/testing.yml +18 -67
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/.pre-commit-config.yaml +3 -3
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/PKG-INFO +2 -2
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docker-compose.https.yml +8 -1
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/requirements.txt +1 -1
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/justfile +15 -12
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/_client.py +21 -4
- meilisearch_python_sdk-3.6.1/meilisearch_python_sdk/_version.py +1 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/index.py +16 -4
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/models/client.py +2 -2
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/models/search.py +14 -1
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/models/settings.py +8 -4
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/pyproject.toml +13 -13
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_async_index_plugins.py +7 -1
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_async_search.py +56 -1
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_index_plugins.py +7 -1
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_search.py +33 -1
- meilisearch_python_sdk-3.6.1/uv.lock +1552 -0
- meilisearch_python_sdk-3.5.1/meilisearch_python_sdk/_version.py +0 -1
- meilisearch_python_sdk-3.5.1/uv.lock +0 -1505
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/.github/FUNDING.yml +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/.github/dependabot.yaml +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/.github/release-draft-template.yaml +0 -0
- /meilisearch_python_sdk-3.5.1/.github/workflows/release-drafter.yaml → /meilisearch_python_sdk-3.6.1/.github/workflows/release-drafter.yml +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/.gitignore +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/CONTRIBUTING.md +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/LICENSE +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/README.md +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/assets/add_in_batches.png +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/assets/searches.png +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/benchmark/run_benchmark.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/codecov.yml +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/datasets/small_movies.json +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docker-compose.yml +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/.nojekyll +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/CNAME +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/async_client_api.md +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/async_index_api.md +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/client_api.md +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/css/custom.css +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/decorators_api.md +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/index.md +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/index_api.md +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/js/umami.js +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/json_handler.md +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/plugins.md +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/docs/pydantic.md +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/.gitignore +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/README.md +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/__init__.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/add_documents_decorator.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/add_documents_in_batches.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/async_add_documents_decorator.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/async_add_documents_in_batches.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/async_documents_and_search_results.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/async_search_tracker.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/async_update_settings.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/documents_and_search_results.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/fastapi_example.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/orjson_example.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/pyproject.toml +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/search_tracker.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/tests/__init__.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/tests/conftest.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/tests/test_async_examples.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/tests/test_examples.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/ujson_example.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/examples/update_settings.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/__init__.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/_http_requests.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/_task.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/_utils.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/decorators.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/errors.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/json_handler.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/models/__init__.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/models/documents.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/models/health.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/models/index.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/models/task.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/models/version.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/plugins.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/py.typed +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/types.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/mkdocs.yaml +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/__init__.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/conftest.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_async_client.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_async_documents.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_async_index.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_client.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_decorators.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_documents.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_errors.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_index.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_utils.py +0 -0
- {meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_version.py +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
name:
|
|
1
|
+
name: Docs Publish
|
|
2
2
|
on:
|
|
3
3
|
release:
|
|
4
4
|
types:
|
|
@@ -11,19 +11,14 @@ jobs:
|
|
|
11
11
|
steps:
|
|
12
12
|
- uses: actions/checkout@v4
|
|
13
13
|
- name: Install uv
|
|
14
|
-
|
|
14
|
+
uses: astral-sh/setup-uv@v3
|
|
15
|
+
with:
|
|
16
|
+
enable-cache: true
|
|
15
17
|
- name: Set up Python
|
|
16
18
|
uses: actions/setup-python@v5
|
|
17
19
|
with:
|
|
18
20
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
19
21
|
- name: Install Dependencies
|
|
20
22
|
run: uv sync --frozen --all-extras
|
|
21
|
-
- name: Build and publish package
|
|
22
|
-
env:
|
|
23
|
-
TWINE_USERNAME: __token__
|
|
24
|
-
TWINE_PASSWORD: "${{ secrets.PYPI_API_KEY }}"
|
|
25
|
-
run: |
|
|
26
|
-
uvx --from build pyproject-build --installer uv
|
|
27
|
-
uvx twine upload dist/*
|
|
28
23
|
- name: Deploy Docs
|
|
29
24
|
run: uv run mkdocs gh-deploy --force
|
{meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/.github/workflows/nightly_testing.yml
RENAMED
|
@@ -5,7 +5,6 @@ on:
|
|
|
5
5
|
# Set with UTC time
|
|
6
6
|
- cron: "0 5 * * *"
|
|
7
7
|
env:
|
|
8
|
-
UV_CACHE_DIR: /tmp/.uv-cache
|
|
9
8
|
PYTHON_VERSION: "3.12"
|
|
10
9
|
jobs:
|
|
11
10
|
random-test-order:
|
|
@@ -15,26 +14,18 @@ jobs:
|
|
|
15
14
|
steps:
|
|
16
15
|
- uses: actions/checkout@v4
|
|
17
16
|
- name: Install uv
|
|
18
|
-
|
|
17
|
+
uses: astral-sh/setup-uv@v3
|
|
18
|
+
with:
|
|
19
|
+
enable-cache: true
|
|
19
20
|
- name: install Just
|
|
20
21
|
uses: taiki-e/install-action@just
|
|
21
22
|
- name: Set up Python
|
|
22
23
|
uses: actions/setup-python@v5
|
|
23
24
|
with:
|
|
24
25
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
25
|
-
- name: Restore uv cache
|
|
26
|
-
uses: actions/cache@v4
|
|
27
|
-
with:
|
|
28
|
-
path: ${{ env.UV_CACHE_DIR }}
|
|
29
|
-
key: uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
30
|
-
restore-keys: |
|
|
31
|
-
uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
32
|
-
uv-${{ runner.os }}
|
|
33
26
|
- name: Install Dependencies
|
|
34
27
|
run: |
|
|
35
28
|
just install
|
|
36
29
|
uv pip install pytest-randomly
|
|
37
30
|
- name: Test with pytest in random order
|
|
38
31
|
run: just test-ci
|
|
39
|
-
- name: Minimize uv cache
|
|
40
|
-
run: uv cache prune --ci
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
name: PyPi Publish
|
|
2
|
+
on:
|
|
3
|
+
release:
|
|
4
|
+
types:
|
|
5
|
+
- published
|
|
6
|
+
env:
|
|
7
|
+
PYTHON_VERSION: "3.12"
|
|
8
|
+
jobs:
|
|
9
|
+
deploy:
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
permissions:
|
|
12
|
+
# For PyPI's trusted publishing.
|
|
13
|
+
id-token: write
|
|
14
|
+
steps:
|
|
15
|
+
- uses: actions/checkout@v4
|
|
16
|
+
- name: Install uv
|
|
17
|
+
uses: astral-sh/setup-uv@v3
|
|
18
|
+
with:
|
|
19
|
+
enable-cache: true
|
|
20
|
+
- name: Set up Python
|
|
21
|
+
uses: actions/setup-python@v5
|
|
22
|
+
with:
|
|
23
|
+
python-version: ${{ env.PYTHON_VERSION }}
|
|
24
|
+
- name: Install Dependencies
|
|
25
|
+
run: uv sync --frozen --all-extras
|
|
26
|
+
- name: Build package
|
|
27
|
+
run: uv build
|
|
28
|
+
- name: Publish package
|
|
29
|
+
run: uv publish
|
|
@@ -6,7 +6,6 @@ on:
|
|
|
6
6
|
- main
|
|
7
7
|
pull_request:
|
|
8
8
|
env:
|
|
9
|
-
UV_CACHE_DIR: /tmp/.uv-cache
|
|
10
9
|
PYTHON_VERSION: "3.9"
|
|
11
10
|
jobs:
|
|
12
11
|
linting:
|
|
@@ -16,25 +15,17 @@ jobs:
|
|
|
16
15
|
- name: install Just
|
|
17
16
|
uses: taiki-e/install-action@just
|
|
18
17
|
- name: Install uv
|
|
19
|
-
|
|
18
|
+
uses: astral-sh/setup-uv@v3
|
|
19
|
+
with:
|
|
20
|
+
enable-cache: true
|
|
20
21
|
- name: Set up Python
|
|
21
22
|
uses: actions/setup-python@v5
|
|
22
23
|
with:
|
|
23
24
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
24
|
-
- name: Restore uv cache
|
|
25
|
-
uses: actions/cache@v4
|
|
26
|
-
with:
|
|
27
|
-
path: ${{ env.UV_CACHE_DIR }}
|
|
28
|
-
key: uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
29
|
-
restore-keys: |
|
|
30
|
-
uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
31
|
-
uv-${{ runner.os }}
|
|
32
25
|
- name: Install Dependencies
|
|
33
26
|
run: just install
|
|
34
27
|
- name: mypy check
|
|
35
28
|
run: just mypy
|
|
36
|
-
- name: Minimize uv cache
|
|
37
|
-
run: uv cache prune --ci
|
|
38
29
|
|
|
39
30
|
parallel-testing:
|
|
40
31
|
strategy:
|
|
@@ -47,19 +38,13 @@ jobs:
|
|
|
47
38
|
- name: install Just
|
|
48
39
|
uses: taiki-e/install-action@just
|
|
49
40
|
- name: Install uv
|
|
50
|
-
|
|
41
|
+
uses: astral-sh/setup-uv@v3
|
|
42
|
+
with:
|
|
43
|
+
enable-cache: true
|
|
51
44
|
- name: Set up Python ${{ matrix.python-version }}
|
|
52
45
|
uses: actions/setup-python@v5
|
|
53
46
|
with:
|
|
54
47
|
python-version: ${{ matrix.python-version }}
|
|
55
|
-
- name: Restore uv cache
|
|
56
|
-
uses: actions/cache@v4
|
|
57
|
-
with:
|
|
58
|
-
path: ${{ env.UV_CACHE_DIR }}
|
|
59
|
-
key: uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
60
|
-
restore-keys: |
|
|
61
|
-
uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
62
|
-
uv-${{ runner.os }}
|
|
63
48
|
- name: Install Dependencies
|
|
64
49
|
run: just install
|
|
65
50
|
- name: Test with pytest
|
|
@@ -69,8 +54,6 @@ jobs:
|
|
|
69
54
|
with:
|
|
70
55
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
71
56
|
fail_ci_if_error: true
|
|
72
|
-
- name: Minimize uv cache
|
|
73
|
-
run: uv cache prune --ci
|
|
74
57
|
|
|
75
58
|
parallel-testing-http2:
|
|
76
59
|
strategy:
|
|
@@ -83,19 +66,13 @@ jobs:
|
|
|
83
66
|
- name: install Just
|
|
84
67
|
uses: taiki-e/install-action@just
|
|
85
68
|
- name: Install uv
|
|
86
|
-
|
|
69
|
+
uses: astral-sh/setup-uv@v3
|
|
70
|
+
with:
|
|
71
|
+
enable-cache: true
|
|
87
72
|
- name: Set up Python ${{ matrix.python-version }}
|
|
88
73
|
uses: actions/setup-python@v5
|
|
89
74
|
with:
|
|
90
75
|
python-version: ${{ matrix.python-version }}
|
|
91
|
-
- name: Restore uv cache
|
|
92
|
-
uses: actions/cache@v4
|
|
93
|
-
with:
|
|
94
|
-
path: ${{ env.UV_CACHE_DIR }}
|
|
95
|
-
key: uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
96
|
-
restore-keys: |
|
|
97
|
-
uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
98
|
-
uv-${{ runner.os }}
|
|
99
76
|
- name: Install Dependencies
|
|
100
77
|
run: just install
|
|
101
78
|
- name: Install truststore
|
|
@@ -117,8 +94,6 @@ jobs:
|
|
|
117
94
|
with:
|
|
118
95
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
119
96
|
fail_ci_if_error: true
|
|
120
|
-
- name: Minimize uv cache
|
|
121
|
-
run: uv cache prune --ci
|
|
122
97
|
|
|
123
98
|
no-parallel-testing:
|
|
124
99
|
strategy:
|
|
@@ -131,19 +106,13 @@ jobs:
|
|
|
131
106
|
- name: install Just
|
|
132
107
|
uses: taiki-e/install-action@just
|
|
133
108
|
- name: Install uv
|
|
134
|
-
|
|
109
|
+
uses: astral-sh/setup-uv@v3
|
|
110
|
+
with:
|
|
111
|
+
enable-cache: true
|
|
135
112
|
- name: Set up Python ${{ matrix.python-version }}
|
|
136
113
|
uses: actions/setup-python@v5
|
|
137
114
|
with:
|
|
138
115
|
python-version: ${{ matrix.python-version }}
|
|
139
|
-
- name: Restore uv cache
|
|
140
|
-
uses: actions/cache@v4
|
|
141
|
-
with:
|
|
142
|
-
path: ${{ env.UV_CACHE_DIR }}
|
|
143
|
-
key: uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
144
|
-
restore-keys: |
|
|
145
|
-
uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
146
|
-
uv-${{ runner.os }}
|
|
147
116
|
- name: Install Dependencies
|
|
148
117
|
run: just install
|
|
149
118
|
- name: Test with pytest
|
|
@@ -153,8 +122,6 @@ jobs:
|
|
|
153
122
|
with:
|
|
154
123
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
155
124
|
fail_ci_if_error: true
|
|
156
|
-
- name: Minimize uv cache
|
|
157
|
-
run: uv cache prune --ci
|
|
158
125
|
|
|
159
126
|
no-parallel-testing-http2:
|
|
160
127
|
strategy:
|
|
@@ -167,19 +134,13 @@ jobs:
|
|
|
167
134
|
- name: install Just
|
|
168
135
|
uses: taiki-e/install-action@just
|
|
169
136
|
- name: Install uv
|
|
170
|
-
|
|
137
|
+
uses: astral-sh/setup-uv@v3
|
|
138
|
+
with:
|
|
139
|
+
enable-cache: true
|
|
171
140
|
- name: Set up Python ${{ matrix.python-version }}
|
|
172
141
|
uses: actions/setup-python@v5
|
|
173
142
|
with:
|
|
174
143
|
python-version: ${{ matrix.python-version }}
|
|
175
|
-
- name: Restore uv cache
|
|
176
|
-
uses: actions/cache@v4
|
|
177
|
-
with:
|
|
178
|
-
path: ${{ env.UV_CACHE_DIR }}
|
|
179
|
-
key: uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
180
|
-
restore-keys: |
|
|
181
|
-
uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
182
|
-
uv-${{ runner.os }}
|
|
183
144
|
- name: Install Dependencies
|
|
184
145
|
run: just install
|
|
185
146
|
- name: Install truststore
|
|
@@ -201,8 +162,6 @@ jobs:
|
|
|
201
162
|
with:
|
|
202
163
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
203
164
|
fail_ci_if_error: true
|
|
204
|
-
- name: Minimize uv cache
|
|
205
|
-
run: uv cache prune --ci
|
|
206
165
|
example-testing:
|
|
207
166
|
strategy:
|
|
208
167
|
fail-fast: false
|
|
@@ -228,22 +187,14 @@ jobs:
|
|
|
228
187
|
- name: install Just
|
|
229
188
|
uses: taiki-e/install-action@just
|
|
230
189
|
- name: Install uv
|
|
231
|
-
|
|
190
|
+
uses: astral-sh/setup-uv@v3
|
|
191
|
+
with:
|
|
192
|
+
enable-cache: true
|
|
232
193
|
- name: Set up Python
|
|
233
194
|
uses: actions/setup-python@v5
|
|
234
195
|
with:
|
|
235
196
|
python-version: "3.11"
|
|
236
|
-
- name: Restore uv cache
|
|
237
|
-
uses: actions/cache@v4
|
|
238
|
-
with:
|
|
239
|
-
path: ${{ env.UV_CACHE_DIR }}
|
|
240
|
-
key: uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
241
|
-
restore-keys: |
|
|
242
|
-
uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
|
|
243
|
-
uv-${{ runner.os }}
|
|
244
197
|
- name: Install Dependencies
|
|
245
198
|
run: just install
|
|
246
199
|
- name: Test Docs Build
|
|
247
200
|
run: just build-docs
|
|
248
|
-
- name: Minimize uv cache
|
|
249
|
-
run: uv cache prune --ci
|
|
@@ -9,12 +9,12 @@ repos:
|
|
|
9
9
|
- id: end-of-file-fixer
|
|
10
10
|
- id: trailing-whitespace
|
|
11
11
|
- repo: https://github.com/pre-commit/mirrors-mypy
|
|
12
|
-
rev: v1.
|
|
12
|
+
rev: v1.13.0
|
|
13
13
|
hooks:
|
|
14
14
|
- id: mypy
|
|
15
|
-
additional_dependencies: [pydantic, types-aiofiles, types-ujson]
|
|
15
|
+
additional_dependencies: [pydantic, orjson, types-aiofiles, types-ujson]
|
|
16
16
|
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
17
|
-
rev: v0.
|
|
17
|
+
rev: v0.7.2
|
|
18
18
|
hooks:
|
|
19
19
|
- id: ruff
|
|
20
20
|
args: [--fix, --exit-non-zero-on-fix]
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: meilisearch-python-sdk
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.6.1
|
|
4
4
|
Summary: A Python client providing both async and sync support for the Meilisearch API
|
|
5
5
|
Project-URL: repository, https://github.com/sanders41/meilisearch-python-sdk
|
|
6
6
|
Project-URL: homepage, https://github.com/sanders41/meilisearch-python-sdk
|
|
@@ -41,7 +41,7 @@ Classifier: Programming Language :: Python :: 3.13
|
|
|
41
41
|
Classifier: Typing :: Typed
|
|
42
42
|
Requires-Python: >=3.9
|
|
43
43
|
Requires-Dist: aiofiles>=0.7
|
|
44
|
-
Requires-Dist: camel-converter>=1.0.0
|
|
44
|
+
Requires-Dist: camel-converter[pydantic]>=1.0.0
|
|
45
45
|
Requires-Dist: eval-type-backport>=0.2.0; python_version < '3.10'
|
|
46
46
|
Requires-Dist: httpx[http2]>=0.17
|
|
47
47
|
Requires-Dist: pydantic>=2.0.0
|
|
@@ -9,4 +9,11 @@ services:
|
|
|
9
9
|
volumes:
|
|
10
10
|
- ./meilisearch.key:/meilisearch.key
|
|
11
11
|
- ./meilisearch.crt:/meilisearch.crt
|
|
12
|
-
command:
|
|
12
|
+
command:
|
|
13
|
+
[
|
|
14
|
+
"meilisearch",
|
|
15
|
+
"--ssl-cert-path",
|
|
16
|
+
"/meilisearch.crt",
|
|
17
|
+
"--ssl-key-path",
|
|
18
|
+
"/meilisearch.key",
|
|
19
|
+
]
|
|
@@ -18,23 +18,23 @@
|
|
|
18
18
|
@ruff-format:
|
|
19
19
|
uv run ruff format meilisearch_python_sdk tests examples
|
|
20
20
|
|
|
21
|
-
@test:
|
|
22
|
-
-uv run pytest
|
|
21
|
+
@test *args="":
|
|
22
|
+
-uv run pytest {{args}}
|
|
23
23
|
|
|
24
|
-
@test-http2:
|
|
25
|
-
-uv run pytest
|
|
24
|
+
@test-http2 *args="":
|
|
25
|
+
-uv run pytest --http2 {{args}}
|
|
26
26
|
|
|
27
|
-
@test-parallel:
|
|
28
|
-
-uv run pytest -n auto -
|
|
27
|
+
@test-parallel *args="":
|
|
28
|
+
-uv run pytest -n auto -m "not no_parallel" {{args}}
|
|
29
29
|
|
|
30
|
-
@test-no-parallel:
|
|
31
|
-
-uv run pytest -
|
|
30
|
+
@test-no-parallel *args="":
|
|
31
|
+
-uv run pytest -m "no_parallel" {{args}}
|
|
32
32
|
|
|
33
|
-
@test-parallel-http2:
|
|
34
|
-
-uv run pytest -n auto -
|
|
33
|
+
@test-parallel-http2 *args="":
|
|
34
|
+
-uv run pytest -n auto -m "not no_parallel" --http2 {{args}}
|
|
35
35
|
|
|
36
|
-
@test-no-parallel-http2:
|
|
37
|
-
-uv run pytest -
|
|
36
|
+
@test-no-parallel-http2 *args="":
|
|
37
|
+
-uv run pytest -m "no_parallel" --http2 {{args}}
|
|
38
38
|
|
|
39
39
|
@test-ci: start-meilisearch-detached && stop-meilisearch
|
|
40
40
|
uv run pytest --cov=meilisearch_python_sdk --cov-report=xml
|
|
@@ -86,5 +86,8 @@
|
|
|
86
86
|
@lock:
|
|
87
87
|
uv lock
|
|
88
88
|
|
|
89
|
+
@lock-upgrade:
|
|
90
|
+
uv lock --upgrade
|
|
91
|
+
|
|
89
92
|
@benchmark: start-meilisearch-detached && stop-meilisearch
|
|
90
93
|
-uv run benchmark/run_benchmark.py
|
{meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/_client.py
RENAMED
|
@@ -24,6 +24,7 @@ from meilisearch_python_sdk.models.health import Health
|
|
|
24
24
|
from meilisearch_python_sdk.models.index import IndexInfo
|
|
25
25
|
from meilisearch_python_sdk.models.search import (
|
|
26
26
|
Federation,
|
|
27
|
+
FederationMerged,
|
|
27
28
|
SearchParams,
|
|
28
29
|
SearchResultsFederated,
|
|
29
30
|
SearchResultsWithUID,
|
|
@@ -587,7 +588,7 @@ class AsyncClient(BaseClient):
|
|
|
587
588
|
self,
|
|
588
589
|
queries: list[SearchParams],
|
|
589
590
|
*,
|
|
590
|
-
federation: Federation | None = None,
|
|
591
|
+
federation: Federation | FederationMerged | None = None,
|
|
591
592
|
hits_type: Any = JsonDict,
|
|
592
593
|
) -> list[SearchResultsWithUID] | SearchResultsFederated:
|
|
593
594
|
"""Multi-index search.
|
|
@@ -628,10 +629,18 @@ class AsyncClient(BaseClient):
|
|
|
628
629
|
else:
|
|
629
630
|
processed_queries = [x.model_dump(by_alias=True) for x in queries]
|
|
630
631
|
|
|
632
|
+
if federation:
|
|
633
|
+
federation_payload = federation.model_dump(by_alias=True)
|
|
634
|
+
if federation.facets_by_index is None:
|
|
635
|
+
del federation_payload["facetsByIndex"]
|
|
636
|
+
|
|
637
|
+
else:
|
|
638
|
+
federation_payload = None
|
|
639
|
+
|
|
631
640
|
response = await self._http_requests.post(
|
|
632
641
|
url,
|
|
633
642
|
body={
|
|
634
|
-
"federation":
|
|
643
|
+
"federation": federation_payload,
|
|
635
644
|
"queries": processed_queries,
|
|
636
645
|
},
|
|
637
646
|
)
|
|
@@ -1396,7 +1405,7 @@ class Client(BaseClient):
|
|
|
1396
1405
|
self,
|
|
1397
1406
|
queries: list[SearchParams],
|
|
1398
1407
|
*,
|
|
1399
|
-
federation: Federation | None = None,
|
|
1408
|
+
federation: Federation | FederationMerged | None = None,
|
|
1400
1409
|
hits_type: Any = JsonDict,
|
|
1401
1410
|
) -> list[SearchResultsWithUID] | SearchResultsFederated:
|
|
1402
1411
|
"""Multi-index search.
|
|
@@ -1437,10 +1446,18 @@ class Client(BaseClient):
|
|
|
1437
1446
|
else:
|
|
1438
1447
|
processed_queries = [x.model_dump(by_alias=True) for x in queries]
|
|
1439
1448
|
|
|
1449
|
+
if federation:
|
|
1450
|
+
federation_payload = federation.model_dump(by_alias=True)
|
|
1451
|
+
if federation.facets_by_index is None:
|
|
1452
|
+
del federation_payload["facetsByIndex"]
|
|
1453
|
+
|
|
1454
|
+
else:
|
|
1455
|
+
federation_payload = None
|
|
1456
|
+
|
|
1440
1457
|
response = self._http_requests.post(
|
|
1441
1458
|
url,
|
|
1442
1459
|
body={
|
|
1443
|
-
"federation":
|
|
1460
|
+
"federation": federation_payload,
|
|
1444
1461
|
"queries": processed_queries,
|
|
1445
1462
|
},
|
|
1446
1463
|
)
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
VERSION = "3.6.1"
|
{meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/meilisearch_python_sdk/index.py
RENAMED
|
@@ -3079,7 +3079,11 @@ class AsyncIndex(_BaseIndex):
|
|
|
3079
3079
|
>>> index = client.index("movies")
|
|
3080
3080
|
>>> await index.update_settings(new_settings)
|
|
3081
3081
|
"""
|
|
3082
|
-
body_dict = {
|
|
3082
|
+
body_dict = {
|
|
3083
|
+
k: v
|
|
3084
|
+
for k, v in body.model_dump(by_alias=True, exclude_none=True).items()
|
|
3085
|
+
if v is not None
|
|
3086
|
+
}
|
|
3083
3087
|
response = await self._http_requests.patch(self._settings_url, body_dict, compress=compress)
|
|
3084
3088
|
|
|
3085
3089
|
return TaskInfo(**response.json())
|
|
@@ -4270,7 +4274,9 @@ class AsyncIndex(_BaseIndex):
|
|
|
4270
4274
|
payload = {}
|
|
4271
4275
|
for key, embedder in embedders.embedders.items():
|
|
4272
4276
|
payload[key] = {
|
|
4273
|
-
k: v
|
|
4277
|
+
k: v
|
|
4278
|
+
for k, v in embedder.model_dump(by_alias=True, exclude_none=True).items()
|
|
4279
|
+
if v is not None
|
|
4274
4280
|
}
|
|
4275
4281
|
|
|
4276
4282
|
response = await self._http_requests.patch(
|
|
@@ -6498,7 +6504,11 @@ class Index(_BaseIndex):
|
|
|
6498
6504
|
>>> index = client.index("movies")
|
|
6499
6505
|
>>> index.update_settings(new_settings)
|
|
6500
6506
|
"""
|
|
6501
|
-
body_dict = {
|
|
6507
|
+
body_dict = {
|
|
6508
|
+
k: v
|
|
6509
|
+
for k, v in body.model_dump(by_alias=True, exclude_none=True).items()
|
|
6510
|
+
if v is not None
|
|
6511
|
+
}
|
|
6502
6512
|
response = self._http_requests.patch(self._settings_url, body_dict, compress=compress)
|
|
6503
6513
|
|
|
6504
6514
|
return TaskInfo(**response.json())
|
|
@@ -7672,7 +7682,9 @@ class Index(_BaseIndex):
|
|
|
7672
7682
|
payload = {}
|
|
7673
7683
|
for key, embedder in embedders.embedders.items():
|
|
7674
7684
|
payload[key] = {
|
|
7675
|
-
k: v
|
|
7685
|
+
k: v
|
|
7686
|
+
for k, v in embedder.model_dump(by_alias=True, exclude_none=True).items()
|
|
7687
|
+
if v is not None
|
|
7676
7688
|
}
|
|
7677
7689
|
|
|
7678
7690
|
response = self._http_requests.patch(
|
|
@@ -23,7 +23,7 @@ class ClientStats(CamelBase):
|
|
|
23
23
|
class _KeyBase(CamelBase):
|
|
24
24
|
uid: str
|
|
25
25
|
name: str | None = None
|
|
26
|
-
description: str
|
|
26
|
+
description: str | None = None
|
|
27
27
|
actions: list[str]
|
|
28
28
|
indexes: list[str]
|
|
29
29
|
expires_at: datetime | None = None
|
|
@@ -59,7 +59,7 @@ class Key(_KeyBase):
|
|
|
59
59
|
|
|
60
60
|
class KeyCreate(CamelBase):
|
|
61
61
|
name: str | None = None
|
|
62
|
-
description: str
|
|
62
|
+
description: str | None = None
|
|
63
63
|
actions: list[str]
|
|
64
64
|
indexes: list[str]
|
|
65
65
|
expires_at: datetime | None = None
|
|
@@ -24,12 +24,24 @@ class FacetSearchResults(CamelBase):
|
|
|
24
24
|
|
|
25
25
|
class Hybrid(CamelBase):
|
|
26
26
|
semantic_ratio: float
|
|
27
|
-
embedder: str
|
|
27
|
+
embedder: str
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
class MergeFacets(CamelBase):
|
|
31
|
+
max_values_per_facet: int
|
|
28
32
|
|
|
29
33
|
|
|
30
34
|
class Federation(CamelBase):
|
|
31
35
|
limit: int = 20
|
|
32
36
|
offset: int = 0
|
|
37
|
+
facets_by_index: dict[str, list[str]] | None = None
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
class FederationMerged(CamelBase):
|
|
41
|
+
limit: int = 20
|
|
42
|
+
offset: int = 0
|
|
43
|
+
facets_by_index: dict[str, list[str]] | None = None
|
|
44
|
+
merge_facets: MergeFacets | None
|
|
33
45
|
|
|
34
46
|
|
|
35
47
|
class SearchParams(CamelBase):
|
|
@@ -99,6 +111,7 @@ class SearchResultsFederated(CamelBase, Generic[T]):
|
|
|
99
111
|
page: int | None = None
|
|
100
112
|
hits_per_page: int | None = None
|
|
101
113
|
semantic_hit_count: int | None = None
|
|
114
|
+
facets_by_index: JsonDict | None = None
|
|
102
115
|
|
|
103
116
|
|
|
104
117
|
class SimilarSearchResults(CamelBase, Generic[T]):
|
|
@@ -49,18 +49,20 @@ class Distribution(CamelBase):
|
|
|
49
49
|
class OpenAiEmbedder(CamelBase):
|
|
50
50
|
source: str = "openAi"
|
|
51
51
|
url: str | None = None
|
|
52
|
-
model: str | None = None
|
|
53
|
-
dimensions: int | None = None
|
|
54
|
-
api_key: str | None = None
|
|
52
|
+
model: str | None = None
|
|
53
|
+
dimensions: int | None = None
|
|
54
|
+
api_key: str | None = None
|
|
55
55
|
document_template: str | None = None
|
|
56
|
+
document_template_max_bytes: int | None = None
|
|
56
57
|
distribution: Distribution | None = None
|
|
57
58
|
|
|
58
59
|
|
|
59
60
|
class HuggingFaceEmbedder(CamelBase):
|
|
60
61
|
source: str = "huggingFace"
|
|
61
|
-
model: str | None = None
|
|
62
|
+
model: str | None = None
|
|
62
63
|
revision: str | None = None
|
|
63
64
|
document_template: str | None = None
|
|
65
|
+
document_template_max_bytes: int | None = None
|
|
64
66
|
distribution: Distribution | None = None
|
|
65
67
|
|
|
66
68
|
|
|
@@ -71,6 +73,7 @@ class OllamaEmbedder(CamelBase):
|
|
|
71
73
|
model: str
|
|
72
74
|
dimensions: int | None = None
|
|
73
75
|
document_template: str | None = None
|
|
76
|
+
document_template_max_bytes: int | None = None
|
|
74
77
|
distribution: Distribution | None = None
|
|
75
78
|
|
|
76
79
|
|
|
@@ -80,6 +83,7 @@ class RestEmbedder(CamelBase):
|
|
|
80
83
|
api_key: str | None = None
|
|
81
84
|
dimensions: int
|
|
82
85
|
document_template: str | None = None
|
|
86
|
+
document_template_max_bytes: int | None = None
|
|
83
87
|
distribution: Distribution | None = None
|
|
84
88
|
headers: JsonDict | None = None
|
|
85
89
|
request: JsonDict
|
|
@@ -25,7 +25,7 @@ classifiers=[
|
|
|
25
25
|
dynamic = ["version"]
|
|
26
26
|
dependencies = [
|
|
27
27
|
"aiofiles>=0.7",
|
|
28
|
-
"camel-converter>=1.0.0",
|
|
28
|
+
"camel-converter[pydantic]>=1.0.0",
|
|
29
29
|
# allows pydantic to use pipe instead of Union
|
|
30
30
|
"eval-type-backport>=0.2.0; python_version < '3.10'",
|
|
31
31
|
"httpx[http2]>=0.17",
|
|
@@ -38,23 +38,23 @@ orjson = ["orjson>=3.10.6"]
|
|
|
38
38
|
ujson = ["ujson>=5.10.0"]
|
|
39
39
|
all = ["orjson", "ujson"]
|
|
40
40
|
|
|
41
|
-
[
|
|
42
|
-
dev
|
|
43
|
-
"mkdocs==1.6.
|
|
44
|
-
"mkdocs-material==9.5.
|
|
45
|
-
"mkdocstrings[python]==0.
|
|
46
|
-
"mypy==1.
|
|
47
|
-
"pre-commit==4.0.
|
|
48
|
-
"pytest==8.3.
|
|
49
|
-
"pytest-cov==
|
|
41
|
+
[dependency-groups]
|
|
42
|
+
dev = [
|
|
43
|
+
"mkdocs==1.6.1",
|
|
44
|
+
"mkdocs-material==9.5.43",
|
|
45
|
+
"mkdocstrings[python]==0.26.2",
|
|
46
|
+
"mypy[faster-cache]==1.13.0",
|
|
47
|
+
"pre-commit==4.0.1",
|
|
48
|
+
"pytest==8.3.3",
|
|
49
|
+
"pytest-cov==6.0.0",
|
|
50
50
|
"pytest-asyncio==0.24.0",
|
|
51
51
|
"pytest-xdist==3.6.1",
|
|
52
|
-
"ruff==0.
|
|
52
|
+
"ruff==0.7.2",
|
|
53
53
|
"types-aiofiles==24.1.0.20240626",
|
|
54
54
|
"typing-extensions==4.12.2",
|
|
55
55
|
"types-ujson==5.10.0.20240515",
|
|
56
|
-
"meilisearch==0.31.
|
|
57
|
-
"rich==13.
|
|
56
|
+
"meilisearch==0.31.6",
|
|
57
|
+
"rich==13.9.3",
|
|
58
58
|
]
|
|
59
59
|
|
|
60
60
|
[tool.hatch.version]
|
{meilisearch_python_sdk-3.5.1 → meilisearch_python_sdk-3.6.1}/tests/test_async_index_plugins.py
RENAMED
|
@@ -112,7 +112,13 @@ class TaskInfoPlugin:
|
|
|
112
112
|
PRE_EVENT = False
|
|
113
113
|
|
|
114
114
|
async def run_plugin(self, event: AsyncEvent, **kwargs: Any) -> TaskInfo:
|
|
115
|
-
return TaskInfo(
|
|
115
|
+
return TaskInfo(
|
|
116
|
+
task_uid=1,
|
|
117
|
+
status="succeeded",
|
|
118
|
+
type="test",
|
|
119
|
+
task_type="test",
|
|
120
|
+
enqueued_at=datetime.now(),
|
|
121
|
+
)
|
|
116
122
|
|
|
117
123
|
|
|
118
124
|
class PrePlugin:
|