Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,14 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-python@v5
with:
python-version: '3.14'
python-version: '3.15'
- name: Setup SSL libs
run: sudo apt-get update -y && sudo apt-get install -y libipc-run-perl && sudo apt-get install pkg-config libssl-dev
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
args: --release --out dist -i 3.10 3.11 3.12 3.13 3.14 pypy3.10 pypy3.11
args: --release --out dist -i 3.10 3.11 3.12 3.13 3.14 3.15 pypy3.10 pypy3.11
sccache: 'true'
manylinux: auto
before-script-linux: |
Expand Down Expand Up @@ -65,13 +65,13 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-python@v5
with:
python-version: '3.14'
python-version: '3.15'
architecture: ${{ matrix.target }}
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
args: --release --out dist -i 3.10 3.11 3.12 3.13 3.14
args: --release --out dist -i 3.10 3.11 3.12 3.13 3.14 3.15
sccache: 'true'
- name: Upload wheels
uses: actions/upload-artifact@v4
Expand All @@ -96,7 +96,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-python@v5
with:
python-version: '3.14'
python-version: '3.15'
# The macOS runner images no longer ship a Rust toolchain on PATH,
# so install it explicitly (including the cross-compilation target).
- name: Setup Rust
Expand All @@ -108,7 +108,7 @@ jobs:
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
args: --release --out dist -i 3.10 3.11 3.12 3.13 3.14 pypy3.10 pypy3.11
args: --release --out dist -i 3.10 3.11 3.12 3.13 3.14 3.15 pypy3.10 pypy3.11
sccache: 'true'
- name: Upload wheels
uses: actions/upload-artifact@v4
Expand Down Expand Up @@ -158,13 +158,13 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-python@v5
with:
python-version: '3.14'
python-version: '3.15'
architecture: x64
- name: Build wheels
uses: messense/maturin-action@v1
with:
target: ${{ matrix.target }}
args: --release --out dist -i 3.10 3.11 3.12 3.13 3.14 pypy3.10 pypy3.11
args: --release --out dist -i 3.10 3.11 3.12 3.13 3.14 3.15 pypy3.10 pypy3.11
manylinux: musllinux_1_2
- name: Upload wheels
uses: actions/upload-artifact@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
name: ${{matrix.job.os}}-${{matrix.py_version}}-${{ matrix.postgres_version }}
strategy:
matrix:
py_version: ["3.10", "3.11", "3.12", "3.13", "3.14"]
py_version: ["3.10", "3.11", "3.12", "3.13", "3.14", "3.15"]
postgres_version: ["14", "15", "16", "17"]
job:
- os: ubuntu-latest
Expand Down
68 changes: 17 additions & 51 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ crate-type = ["cdylib"]

[dependencies]
deadpool-postgres = { git = "https://github.com/psqlpy-python/deadpool.git", branch = "psqlpy" }
pyo3 = { version = "0.25.1", features = [
pyo3 = { version = "0.29", features = [
"chrono",
"experimental-async",
"rust_decimal",
Expand All @@ -19,7 +19,7 @@ pyo3 = { version = "0.25.1", features = [
"multiple-pymethods",
"generate-import-lib",
] }
pyo3-async-runtimes = { git = "https://github.com/psqlpy-python/pyo3-async-runtimes.git", branch = "psqlpy", features = [
pyo3-async-runtimes = { version = "0.29", features = [
"tokio-runtime",
] }

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[![PyPI - Python Version](https://img.shields.io/badge/PYTHON-3.10_%7C_3.11_%7C_3.12_%7C_3.13_%7C_3.14-blue?style=for-the-badge
[![PyPI - Python Version](https://img.shields.io/badge/PYTHON-3.10_%7C_3.11_%7C_3.12_%7C_3.13_%7C_3.14_%7C_3.15-blue?style=for-the-badge
)](https://pypi.org/project/psqlpy/)
[![PyPI - Python Version](https://img.shields.io/badge/Tested%20On%20PostgreSQL-14%20%7C%2015%20%7C%2016%20%7C17-2be28a?style=for-the-badge
)](https://pypi.org/project/psqlpy/)
Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ classifiers = [
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Programming Language :: Python :: 3.15",
]
authors = [{ email = "askiselev00@gmail.com" }, { name = "Kiselev Aleksandr" }]
maintainers = [{ name = "Kiselev Aleksandr", email = "askiselev00@gmail.com" }]
Expand Down
4 changes: 2 additions & 2 deletions src/connection/impls.rs
Original file line number Diff line number Diff line change
Expand Up @@ -578,7 +578,7 @@ impl PSQLPyConnection {
// one here for all remaining rows — independent of batch size, not per-row.
let first_pp = template.into_prepared_parameters();
let remaining_pp: PSQLPyResult<Vec<_>> = if parameters.len() > 1 {
Python::with_gil(|gil| {
Python::attach(|gil| {
parameters[1..]
.iter()
.map(|param_set| {
Expand Down Expand Up @@ -757,7 +757,7 @@ impl PSQLPyConnection {
.fetch_row_raw(querystring, parameters, prepared)
.await?;

Python::with_gil(|gil| match result.columns().first() {
Python::attach(|gil| match result.columns().first() {
Some(first_column) => postgres_to_py(gil, &result, first_column, 0, &None),
None => Ok(gil.None()),
})
Expand Down
6 changes: 3 additions & 3 deletions src/driver/common.rs
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ macro_rules! impl_binary_copy_method {
schema_name: Option<String>,
) -> PSQLPyResult<u64> {
let (db_client, mut bytes_mut) =
Python::with_gil(|gil| -> PSQLPyResult<(Option<_>, BytesMut)> {
Python::attach(|gil| -> PSQLPyResult<(Option<_>, BytesMut)> {
let db_client = self_.borrow(gil).conn.clone();

let Some(db_client) = db_client else {
Expand Down Expand Up @@ -388,7 +388,7 @@ macro_rules! impl_copy_records_method {
columns: Option<Vec<String>>,
schema_name: Option<String>,
) -> PSQLPyResult<u64> {
let db_client = Python::with_gil(|gil| self_.borrow(gil).conn.clone());
let db_client = Python::attach(|gil| self_.borrow(gil).conn.clone());

let Some(db_client) = db_client else {
return Ok(0);
Expand Down Expand Up @@ -461,7 +461,7 @@ macro_rules! impl_copy_records_method {
// Vec<Vec<Py<PyAny>>> then re-visit for DTO conversion).
let mut chunks: Vec<bytes::Bytes> = Vec::new();

let gil_result: PSQLPyResult<()> = Python::with_gil(|gil| {
let gil_result: PSQLPyResult<()> = Python::attach(|gil| {
let n_cols = column_types.len();
let mut buf = BytesMut::with_capacity(COPY_BUFFER_SIZE);
// Scratch vec allocated once and cleared between rows (T3#10).
Expand Down
Loading