Skip to content

Commit 74fd5bc

Browse files
authored
Merge release-candidate/2025-01 (#455)
## Problem In preparation to release v6, we need to merge recent changes in the release-candidate/2025-01 branch. ## Solution Merge conflicts seem limited to just a few things in the pyproject.toml and poetry.lock file, as well as a few method signatures modified to indicate `None` as return type. So I think this should go pretty smoothly.
2 parents a023f60 + f0f1555 commit 74fd5bc

File tree

405 files changed

+28802
-25323
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

405 files changed

+28802
-25323
lines changed

.github/actions/build-docs/action.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@ runs:
2121
- name: Build html documentation
2222
shell: bash
2323
run: |
24-
poetry run pdoc pinecone '!pinecone.core' '!pinecone.utils' --favicon ./favicon-32x32.png --docformat google -o ./docs
24+
poetry run pdoc pinecone '!pinecone.core' '!pinecone.utils' --favicon ./favicon-32x32.png --docformat google -o ./pdoc

.github/actions/setup-poetry/action.yml

+7-1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ inputs:
1313
description: 'Install typing dependencies (mypy, type stubs, etc)'
1414
required: true
1515
default: 'true'
16+
include_asyncio:
17+
description: 'Install asyncio dependencies'
18+
required: true
19+
default: 'false'
1620

1721
runs:
1822
using: 'composite'
@@ -26,8 +30,10 @@ runs:
2630
INCLUDE_GRPC: ${{ inputs.include_grpc }}
2731
INCLUDE_DEV: ${{ inputs.include_dev }}
2832
INCLUDE_TYPES: ${{ inputs.include_types }}
33+
INCLUDE_ASYNCIO: ${{ inputs.include_asyncio }}
2934
run: |
3035
GRPC_FLAG=$( [ "$INCLUDE_GRPC" = "true" ] && echo "--extras grpc" || echo "" )
36+
ASYNCIO_FLAG=$( [ "$INCLUDE_ASYNCIO" = "true" ] && echo "--extras asyncio" || echo "" )
3137
DEV_FLAG=$( [ "$INCLUDE_DEV" = "false" ] && echo "--without dev" || echo "" )
3238
TYPING_FLAG=$( [ "$INCLUDE_TYPES" = "true" ] && echo "--with types" || echo "" )
33-
poetry install $DEV_FLAG $TYPING_FLAG $GRPC_FLAG
39+
poetry install $DEV_FLAG $TYPING_FLAG $GRPC_FLAG $ASYNCIO_FLAG
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: 'Test Asyncio'
2+
description: 'Runs tests on the Pinecone data plane'
3+
4+
inputs:
5+
spec:
6+
description: 'The deploy spec of the index'
7+
required: true
8+
use_grpc:
9+
description: 'Whether to use gRPC or REST'
10+
required: true
11+
freshness_timeout_seconds:
12+
description: 'The number of seconds to wait for the index to become fresh'
13+
required: false
14+
default: '60'
15+
PINECONE_API_KEY:
16+
description: 'The Pinecone API key'
17+
required: true
18+
python_version:
19+
description: 'The version of Python to use'
20+
required: false
21+
default: '3.9'
22+
23+
runs:
24+
using: 'composite'
25+
steps:
26+
- name: Set up Python
27+
uses: actions/setup-python@v5
28+
with:
29+
python-version: ${{ inputs.python_version }}
30+
31+
- name: Setup Poetry
32+
uses: ./.github/actions/setup-poetry
33+
with:
34+
include_grpc: ${{ inputs.use_grpc }}
35+
include_dev: 'true'
36+
include_asyncio: 'true'
37+
38+
- name: Run data plane tests
39+
id: data-plane-asyncio-tests
40+
shell: bash
41+
run: poetry run pytest tests/integration/data_asyncio -s -vv
42+
env:
43+
PINECONE_API_KEY: ${{ inputs.PINECONE_API_KEY }}
44+
USE_GRPC: ${{ inputs.use_grpc }}
45+
SPEC: ${{ inputs.spec }}
46+
FRESHNESS_TIMEOUT_SECONDS: ${{ inputs.freshness_timeout_seconds }}

.github/actions/test-data-plane/action.yaml

+1-13
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,6 @@
11
name: 'Test Data Plane'
22
description: 'Runs tests on the Pinecone data plane'
33

4-
# - pod vs serverless
5-
# - grpc vs rest
6-
# - metric -> vector vs sparse vector
7-
# - namespace: default vs custom
8-
# - environment: free vs paid
9-
# - with metadata vs without metadata
10-
114
inputs:
125
metric:
136
description: 'The metric of the index'
@@ -59,13 +52,8 @@ runs:
5952
- name: Run data plane tests
6053
id: data-plane-tests
6154
shell: bash
62-
run: poetry run pytest tests/integration/data --ddtrace
55+
run: poetry run pytest tests/integration/data
6356
env:
64-
DD_CIVISIBILITY_AGENTLESS_ENABLED: true
65-
DD_API_KEY: ${{ inputs.DATADOG_API_KEY }}
66-
DD_SITE: datadoghq.com
67-
DD_ENV: ci
68-
DD_SERVICE: pinecone-python-client
6957
PINECONE_API_KEY: ${{ inputs.PINECONE_API_KEY }}
7058
USE_GRPC: ${{ inputs.use_grpc }}
7159
METRIC: ${{ inputs.metric }}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: 'Test aiohttp dependencies'
2+
description: 'Runs asyncio sanity test with specific aiohttp dependencies'
3+
4+
inputs:
5+
PINECONE_API_KEY:
6+
description: 'The Pinecone API key'
7+
required: true
8+
index_name:
9+
description: 'The name of the index'
10+
required: true
11+
python_version:
12+
description: 'The version of Python to use'
13+
required: false
14+
default: '3.9'
15+
aiohttp_version:
16+
description: 'The version of aiohttp to install'
17+
required: true
18+
19+
runs:
20+
using: 'composite'
21+
steps:
22+
- name: Set up Python
23+
uses: actions/setup-python@v5
24+
with:
25+
python-version: ${{ inputs.python_version }}
26+
27+
- name: Setup Poetry
28+
uses: ./.github/actions/setup-poetry
29+
with:
30+
include_grpc: false
31+
include_types: false
32+
include_asyncio: true
33+
34+
- name: 'Install aiohttp ${{ matrix.aiohttp-version }}'
35+
run: 'poetry add aiohttp==${{ matrix.aiohttp-version }}'
36+
shell: bash
37+
38+
- uses: nick-fields/retry@v3
39+
with:
40+
timeout_minutes: 5
41+
max_attempts: 3
42+
retry_on: error
43+
command: poetry run pytest tests/dependency/asyncio-rest -s -v
44+
env:
45+
PINECONE_API_KEY: '${{ inputs.PINECONE_API_KEY }}'
46+
INDEX_NAME: '${{ inputs.index_name }}'

.github/actions/test-dependency-grpc/action.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ runs:
6060
timeout_minutes: 5
6161
max_attempts: 3
6262
retry_on: error
63-
command: poetry run pytest tests/dependency/grpc -s -v --ddtrace
63+
command: poetry run pytest tests/dependency/grpc -s -v
6464
env:
6565
PINECONE_API_KEY: ${{ inputs.PINECONE_API_KEY }}
6666
INDEX_NAME: ${{ inputs.index_name }}

.github/actions/test-dependency-rest/action.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ runs:
3939
timeout_minutes: 5
4040
max_attempts: 3
4141
retry_on: error
42-
command: poetry run pytest tests/dependency/rest -s -v --ddtrace
42+
command: poetry run pytest tests/dependency/rest -s -v
4343
env:
4444
PINECONE_API_KEY: '${{ inputs.PINECONE_API_KEY }}'
4545
INDEX_NAME: '${{ inputs.index_name }}'

.github/workflows/alpha-release.yaml

+13-14
Original file line numberDiff line numberDiff line change
@@ -24,22 +24,22 @@ on:
2424
default: 'rc1'
2525

2626
jobs:
27-
unit-tests:
28-
uses: './.github/workflows/testing-unit.yaml'
29-
secrets: inherit
30-
integration-tests:
31-
uses: './.github/workflows/testing-integration.yaml'
32-
secrets: inherit
33-
dependency-tests:
34-
uses: './.github/workflows/testing-dependency.yaml'
35-
secrets: inherit
27+
# unit-tests:
28+
# uses: './.github/workflows/testing-unit.yaml'
29+
# secrets: inherit
30+
# integration-tests:
31+
# uses: './.github/workflows/testing-integration.yaml'
32+
# secrets: inherit
33+
# dependency-tests:
34+
# uses: './.github/workflows/testing-dependency.yaml'
35+
# secrets: inherit
3636

3737
pypi:
3838
uses: './.github/workflows/publish-to-pypi.yaml'
39-
needs:
40-
- unit-tests
41-
- integration-tests
42-
- dependency-tests
39+
# needs:
40+
# - unit-tests
41+
# - integration-tests
42+
# - dependency-tests
4343
with:
4444
isPrerelease: true
4545
ref: ${{ inputs.ref }}
@@ -49,4 +49,3 @@ jobs:
4949
secrets:
5050
PYPI_USERNAME: __token__
5151
PYPI_PASSWORD: ${{ secrets.PROD_PYPI_PUBLISH_TOKEN }}
52-

.github/workflows/build-and-publish-docs.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
env:
2525
SSH_DEPLOY_KEY: ${{ secrets.SSH_DEPLOY_KEY }}
2626
with:
27-
source-directory: docs
27+
source-directory: pdoc
2828
destination-github-username: pinecone-io
2929
destination-repository-name: sdk-docs
3030
user-email: [email protected]

.github/workflows/lint.yaml

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
name: "Lint"
2-
on: [pull_request]
2+
on:
3+
workflow_call: {}
34

45
jobs:
56
lint:

.github/workflows/migration-paths.yaml

-47
This file was deleted.

.github/workflows/pr.yaml

+11-3
Original file line numberDiff line numberDiff line change
@@ -8,21 +8,29 @@ on:
88
workflow_dispatch: {}
99

1010
jobs:
11+
linting:
12+
uses: './.github/workflows/lint.yaml'
13+
1114
unit-tests:
1215
uses: './.github/workflows/testing-unit.yaml'
1316
secrets: inherit
17+
1418
integration-tests:
1519
uses: './.github/workflows/testing-integration.yaml'
1620
secrets: inherit
21+
needs: unit-tests
22+
1723
dependency-tests:
1824
uses: './.github/workflows/testing-dependency.yaml'
1925
secrets: inherit
26+
needs: unit-tests
27+
2028
package:
2129
name: Check packaging
2230
runs-on: ubuntu-latest
2331
strategy:
2432
matrix:
25-
python-version: [3.8, 3.12]
33+
python-version: [3.9, 3.13]
2634
steps:
2735
- uses: actions/checkout@v4
2836
- name: Set up Python ${{ matrix.python-version }}
@@ -33,7 +41,7 @@ jobs:
3341
uses: ./.github/actions/setup-poetry
3442
- name: Package
3543
run: poetry build
36-
44+
3745
build-docs:
3846
name: Build docs with pdoc
3947
runs-on: ubuntu-latest
@@ -43,4 +51,4 @@ jobs:
4351
- name: Build docs with pdoc
4452
uses: './.github/actions/build-docs'
4553
with:
46-
python-version: 3.11
54+
python-version: 3.11

.github/workflows/publish-to-pypi.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ jobs:
7474
- name: Setup Python
7575
uses: actions/setup-python@v5
7676
with:
77-
python-version: 3.x
77+
python-version: 3.12
7878

7979
- name: Setup Poetry
8080
uses: ./.github/actions/setup-poetry
@@ -109,13 +109,13 @@ jobs:
109109
run: |
110110
# Add the original pinecone client version file to git
111111
# Even though Poetry is now the preferred means of working
112-
# with this project, since this __version__ file has been the
112+
# with this project, since this __version__ file has been the
113113
# one source of truth for our release process. We need to maintain
114114
# both files for the time being, and they should always contain the
115115
# identical package version
116116
git add pinecone/__version__
117117
# Add also the pyproject.toml, which is Poetry's source of truth, so
118-
# that we maintain the exact same version across the two files
118+
# that we maintain the exact same version across the two files
119119
git add pyproject.toml
120120
git commit -m "[skip ci] Bump version to ${{ steps.bump.outputs.VERSION_TAG }}"
121121
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Dependency Testing (Asyncio)
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
index_name:
7+
required: true
8+
type: string
9+
10+
jobs:
11+
dependency-matrix-asyncio-rest:
12+
name: Deps (Asyncio REST)
13+
runs-on: ubuntu-latest
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
python_version:
18+
- 3.9
19+
- 3.13
20+
aiohttp_version:
21+
- 3.9.0
22+
- 3.11.5
23+
steps:
24+
- uses: actions/checkout@v4
25+
- uses: ./.github/actions/test-dependency-asyncio-rest
26+
with:
27+
python_version: '${{ matrix.python_version }}'
28+
index_name: '${{ inputs.index_name }}'
29+
PINECONE_API_KEY: '${{ secrets.PINECONE_API_KEY }}'
30+
aiohttp_version: '${{ matrix.aiohttp_version }}'

0 commit comments

Comments
 (0)