Skip to content

Commit eb5072a

Browse files
committed
Make build check work on Python 3.11
1 parent f2a63ce commit eb5072a

File tree

3 files changed

+22
-14
lines changed

3 files changed

+22
-14
lines changed

.buildkite/pipeline.yml

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -585,26 +585,20 @@ steps:
585585
steps:
586586
- label: ":python: Build Python {{matrix.python_version}} {{matrix.package_path}} package"
587587
key: build_python_package
588-
agents:
589-
provider: "gcp"
590-
machineType: "n1-standard-8"
591-
useVault: true
592-
image: family/enterprise-search-ubuntu-2204-connectors-py
588+
<<: *test-agents
593589
matrix:
594590
setup:
595591
python_version:
596592
- "3.10"
597593
- "3.11"
598594
package_path:
599595
- "app/connectors_service"
600-
commands:
601-
- "cd {{matrix.package_path}}"
602-
- "python{{matrix.python_version}} -m pip install --upgrade build twine"
603-
- "python{{matrix.python_version}} -m build"
604-
- "ls -lah dist/"
605-
- "python{{matrix.python_version}} -m twine check dist/*"
606-
artifact_paths:
607-
- "{{matrix.package_path}}/dist/*"
596+
- "libs/connectors_sdk"
597+
env:
598+
PYTHON_VERSION: "{{ matrix.python_version }}"
599+
PACKAGE_PATH: "{{ matrix.package_path }}"
600+
command: ".buildkite/test_python_packages.sh"
601+
timeout_in_minutes: 10
608602

609603
# ----
610604
# DRA publishing

.buildkite/test_python_packages.sh

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
#!/bin/bash
2+
3+
# !!! WARNING DO NOT add -x to avoid leaking vault passwords
4+
set -euo pipefail
5+
6+
source .buildkite/shared.sh
7+
8+
init_python
9+
10+
cd "$PACKAGE_PATH"
11+
python -m pip install --upgrade build twine
12+
python -m build
13+
ls -lah dist/
14+
python -m twine check dist/*

libs/connectors_sdk/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@ readme = "README.md"
1010
authors = [
1111
{ name = "Search Extract and Transform Team", email = "[email protected]" }
1212
]
13+
license = "Elastic-2.0"
1314
classifiers = [
1415
"Programming Language :: Python",
1516
"Programming Language :: Python :: 3.10",
1617
"Programming Language :: Python :: 3.11",
17-
"License :: OSI Approved :: Apache Software License",
1818
"Programming Language :: Python :: 3 :: Only",
1919
]
2020
requires-python = ">=3.10,<3.12"

0 commit comments

Comments
 (0)