skillfed

queries

Simplified PostgreSQL client built upon Psycopg2

queries v2.1.1 283.9K downloads/30d#8,070 on PyPI254
Permissive license BSD Abandoned released

What it is and what it does

Queries wraps psycopg2 to reduce boilerplate when building PostgreSQL client applications. It provides a session-based API that handles connection pooling internally, URI-based connection configuration, and automatic type support for UUIDs and Unicode. The package also includes a Tornado integration for asynchronous query execution in web applications.

The package was last released on 2021-11-16 and is no longer maintained. While it remains in production/stable status according to its classifiers, the lack of updates means it has not been tested against recent Python or PostgreSQL versions and will not receive bug fixes or security updates.

Use it for:

  • Building synchronous PostgreSQL client scripts or applications where connection pooling and URI-based configuration reduce setup code.
  • Integrating PostgreSQL queries into Tornado web applications using the TornadoSession class for asynchronous database access.
  • Maintaining legacy applications that already depend on queries and do not require modern Python version support.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Queries is a simplified wrapper around psycopg2 that provides a session-based API for connecting to and querying PostgreSQL databases, with built-in connection pooling and support for both synchronous and asynchronous (Tornado) operations.

No, not for new projects. The package is abandoned (last release 2021-11-16) and will not receive maintenance, security updates, or compatibility fixes. For new PostgreSQL work, use actively maintained alternatives. Only consider it if you are maintaining existing code that already depends on it and cannot migrate.

Install

queries on PyPI

pip

pip install queries

uv

uv add queries

poetry

poetry add queries

Installing queries

Before you install

Installation friction is high with no runtime dependencies listed. The package has not been maintained since 2021-11-16 and is marked as abandoned, meaning it will not receive updates for modern Python or PostgreSQL versions.

License in practice

Queries is BSD licensed under a permissive license, meaning you can use, modify, and distribute it freely with minimal restrictions, though you must include the license notice.

Quickstart

import queries

with queries.Session('postgresql://user@localhost/dbname') as session:
    for row in session.query('SELECT * FROM table_name'):
        print(row)

Requires a running PostgreSQL server and psycopg2 (or psycopg2cffi for PyPy) to be installed; the package itself declares no explicit runtime dependencies in its metadata.

Verify before relying

  • Whether psycopg2 is an implicit runtime dependency not declared in package metadata
  • Current compatibility with Python versions beyond 3.8 given the maintenance gap since 2021-11-16
  • Whether connection pooling behavior remains stable under modern PostgreSQL versions

Package facts

License BSD (permissive)
Python support not specified
Install friction high — source build required
Runtime dependencies none
Maintenance abandoned — 1,732 days since the last release
Last repo commit
First released
Downloads 283,931/month — #8,070 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: queries-2.1.1.tar.gz

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: BSD LicenseOperating System :: OS IndependentProgramming Language :: Python :: 2Programming Language :: Python :: 2.7Programming Language :: Python :: 3Programming Language :: Python :: 3.4Programming Language :: Python :: 3.5Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: Implementation :: CPythonProgramming Language :: Python :: Implementation :: PyPyTopic :: DatabaseTopic :: Software Development :: Libraries

Tags

postgresql client wrapperpsycopg2 simplified apipostgres connection poolingtornado async postgresqlpython postgresql sessionpostgres query builderdatabase connection management
abandonedlegacy-maintenance-only

More Libraries packages