Skip to main content

Unofficial helper utilities for PyMySQL-based applications.

Project description

pymysql-dist

pymysql-dist is an unofficial support library for applications that use PyMySQL.

It provides small, readable helpers for connection settings, safe SQL snippets, basic CRUD operations, pagination, row normalization, and SQL script loading. The package is intentionally simple, so it can be used as a reference while building desktop or educational database applications.

This project is not affiliated with the PyMySQL project.

Installation

pip install pymysql-dist

Quick Example

from pymysql_dist import DatabaseConfig, connection, TableGateway

config = DatabaseConfig(
    host="localhost",
    user="root",
    password="",
    database="shop",
)

with connection(config) as conn:
    products = TableGateway(conn, "products")
    rows = products.all(order_by="id")

Environment Configuration

from pymysql_dist import DatabaseConfig

config = DatabaseConfig.from_env()

Default environment variables:

  • MYSQL_HOST
  • MYSQL_PORT
  • MYSQL_USER
  • MYSQL_PASSWORD
  • MYSQL_DATABASE
  • MYSQL_CHARSET

Modules

  • pymysql_dist.config - database configuration.
  • pymysql_dist.connection - connection helpers.
  • pymysql_dist.crud - small table gateway.
  • pymysql_dist.sql - SQL builders, filters, and sorting helpers.
  • pymysql_dist.schema - SQL file loading and script execution.
  • pymysql_dist.rows - row conversion helpers.
  • pymysql_dist.pagination - pagination data structures.
  • pymysql_dist.qt - lightweight table data adapters.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pymysql_dist-0.1.0.tar.gz (10.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pymysql_dist-0.1.0-py3-none-any.whl (14.5 kB view details)

Uploaded Python 3

File details

Details for the file pymysql_dist-0.1.0.tar.gz.

File metadata

  • Download URL: pymysql_dist-0.1.0.tar.gz
  • Upload date:
  • Size: 10.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for pymysql_dist-0.1.0.tar.gz
Algorithm Hash digest
SHA256 67e523053a111e3a4c93e732e944fa40bdc019f7d060380ecff9976a226da807
MD5 7515bfcee8886257f9552fa14e7be7dc
BLAKE2b-256 1bf7967305e53e38eec4a8f6a135fc3ec2b88046ea293e1ec59523fb11b2f502

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymysql_dist-0.1.0.tar.gz:

Publisher: publish.yml on Leevandr/pymysql-dist

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pymysql_dist-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: pymysql_dist-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 14.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for pymysql_dist-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 70b7876a468a2edce64a084968b9493b53f49f3edeb1f76a95c9b661eba37e70
MD5 b16d48d5dacc88243385499396d63737
BLAKE2b-256 84c78c4fc889f2dc9ee6e29942aa9e7207eef1d7fce1b7b15bcfc35883f9ff7c

See more details on using hashes here.

Provenance

The following attestation bundles were made for pymysql_dist-0.1.0-py3-none-any.whl:

Publisher: publish.yml on Leevandr/pymysql-dist

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page