thehardwarestore.ai

where AI agents shop for the right tools

── 99246 repos indexed ── | filtered by tag: sqlalchemy
jowilf/starlette-admin β˜… 1031 95 APPLICATION

starlette-admin is a comprehensive admin interface library for Starlette and FastAPI applications, providing auto-generated CRUD views with search, sorting, filtering, inline editing, batch actions, import/export, and a widget-based dashboard system. It is designed as an ASGI middleware that mounts onto a Starlette app, using Jinja2 templating, itsdangerous for cookie signing, and python-multipart for file uploads. The architecture is backend-agnostic: the core defines abstract interfaces for model views, fields, filters, storage, and authentication, while optional ORM integrations (SQLAlchemy, SQLModel, Beanie, MongoEngine, Tortoise) provide concrete implementations. The library also includes a plugin and theme system, internationalization (Babel), CSRF protection, flash messages, and a full event lifecycle for audit and custom logic. It is a pure application libraryβ€”no data research or analytics components.

RATING: 9.3/10 MAINT: active DRIFT: low
β–Έ 3 reusable components found
pyathena-dev/PyAthena β˜… 492 112 APPLICATION

PyAthena is a Python client library for Amazon Athena that implements the PEP 249 DB-API 2.0 specification with both synchronous and asynchronous execution models. It provides multiple cursor implementations (CSV, Arrow, Pandas, Polars) and an UNLOAD-based Parquet path for large-scale ETL, plus a SQLAlchemy dialect for ORM-style access. The library handles Athena's S3-backed query lifecycle, result pagination, type conversion heuristics for complex types, and the documented null-vs-empty-string semantics that differ between CSV (GetQueryResults) and Parquet (UNLOAD) paths. The architecture is a layered client: a core connection/cursor layer implementing the DB-API contract, an async sibling layer (AioCursor and related classes), and optional integration layers for pandas, Polars, Arrow, and SQLAlchemy. Key entry points are the connection factory, cursor classes, and the SQLAlchemy dialect. The library depends on boto3/botocore for AWS API calls, with optional dependencies for pyarrow, pandas, polars, and SQLAlchemy. It also ships an S3 file system abstraction (sync and async) with caching, multipart uploads, and versioning, plus a benchmark framework that spawns isolated subprocesses with an Observer pattern for SDK event monitoring, memory/thread sampling, and incremental result reporting. Security is treated seriously: the codebase maintains Trino-vs-Hive escaping distinctions for identifiers and string literals, and tests explicitly verify injection resistance. The project is actively maintained with a defined contribution workflow, CI running lint and Sphinx builds, and a worktree-based PR process. Documentation covers Athena-specific limitations including Iceberg type constraints, naming rules, and the fact that Athena does not return element-level type information for complex types, so the converter applies documented heuristics. The project uses hatch-vcs for versioning (pyathena/_version.py must never be edited manually) and supports schema-qualified queries against ENV.schema.

RATING: 9.1/10 MAINT: active DRIFT: low
β–Έ 6 reusable components found
tedivm/robs_awesome_python_template β˜… 312 23 APPLICATION

This is a comprehensive Cookiecutter template for generating production-ready Python projects. It is not a running application itself but a project generator that produces applications, libraries, or services based on user-selected features. The template includes sophisticated post-generation hooks that surgically remove unused files and configure dependencies, Docker Compose services, CI/CD workflows, and documentation based on the chosen options. It enforces modern Python practices: uv for package management, Ruff for linting/formatting, mypy for type checking, pytest for testing, and Pydantic Settings for configuration. The generated projects can include FastAPI, Celery, SQLAlchemy, QuasiQueue, aiocache, Jinja2, Typer CLI, Docker, and GitHub Actions. The template itself demonstrates high craftsmanship with clean Jinja2 templating, conditional logic, and a well-organized file structure. It is actively maintained and uses current tooling (uv, Ruff, etc.), indicating low technical drift.

RATING: 8.9/10 MAINT: active DRIFT: low
β–Έ 5 reusable components found
Mause/duckdb_engine β˜… 497 70 APPLICATION

This repository provides a SQLAlchemy dialect for DuckDB, enabling DuckDB to be used as a database backend within SQLAlchemy's ORM and Core APIs. It maps DuckDB's type system to SQLAlchemy types, handles connection management (including in-memory and file-based databases), supports reflection (schema introspection), and integrates with DuckDB extensions. The dialect is built on top of the PostgreSQL psycopg2 dialect, customizing it for DuckDB's capabilities and limitations. The source code is well-structured, extensively tested, and actively maintained, with support for DuckDB versions 0.5.0 through 1.2.2 and SQLAlchemy 1.3 through 2.0.35.

RATING: 8.5/10 MAINT: active DRIFT: low
β–Έ 1 reusable components found
uralbash/sqlalchemy_mptt β˜… 200 33 APPLICATION

sqlalchemy_mptt is a Python library that provides SQLAlchemy mixins for implementing Modified Preorder Tree Traversal (MPTT) with SQLAlchemy models. It automatically maintains tree structure through SQLAlchemy event listeners, handling insert, update, and delete operations while preserving tree integrity. The library supports multi-tree scenarios, various primary key types, and provides methods for tree traversal, drilldown operations, and path-to-root queries. The architecture centers around the BaseNestedSets mixin class that adds tree-specific columns and methods to SQLAlchemy models, complemented by a TreesManager that handles SQLAlchemy events to automatically maintain lft, rgt, level, and tree_id attributes. The library demonstrates strong engineering practices with a compatibility layer for SQLAlchemy versions, comprehensive test suite, and active maintenance with recent support for SQLAlchemy 2.0 and modern Python versions.

RATING: 8.4/10 MAINT: active DRIFT: low
β–Έ 2 reusable components found
benavlabs/FastAPI-boilerplate β˜… 2071 306 APPLICATION

This repository is a production-grade FastAPI boilerplate (named 'Fastro') designed to accelerate building SaaS backends. It provides a complete, modular architecture with three layers: infrastructure (config, caching, rate limiting, auth, logging, database), interfaces (REST API, admin panel), and vertical-slice modules (user, tier, API keys, rate limits). The codebase is fully async, uses SQLAlchemy 2.0 with `MappedAsDataclass`, Pydantic v2, and FastCRUD for generic CRUD operations. Authentication is session-based via the external `crudauth` library, with server-side sessions, CSRF, OAuth (Google wired), and API key support. Caching and rate limiting follow a provider pattern with swappable Redis/Memcached backends. The repo also includes a CLI tool (`bp`) with plugin discovery for commands and features, a multi-stage Dockerfile, Alembic migrations, and extensive documentation (though some docs describe aspirational features not yet implemented). A paid fork (FastroAI) adds payments, email, and frontend, but the free boilerplate is self-contained and functional.

RATING: 8.2/10 MAINT: active DRIFT: low
β–Έ 6 reusable components found
xnuinside/omymodels β˜… 199 27 APPLICATION

O! My Models (omymodels) is a Python library for generating various Python model types from SQL DDL and converting between model types. It supports SQLAlchemy ORM and Core, GinoORM, Pydantic v1/v2, SQLModel, Python Dataclasses, Enums, and OpenAPI 3 schemas. The architecture follows a pipeline: SQL DDL parsing β†’ normalization β†’ type conversion β†’ model generation β†’ Jinja2 template rendering. Key features include a plugin system for custom generators, bidirectional model conversion, and both programmatic and CLI interfaces. The library is well-structured with clear separation of dependencies, comprehensive testing, and active maintenance.

RATING: 7.9/10 MAINT: maintained DRIFT: low
β–Έ 1 reusable components found
aio-libs/aiomysql β˜… 1895 272 APPLICATION

aiomysql is a pure-Python MySQL/MariaDB client library for asyncio. It is effectively a port of PyMySQL's blocking driver with async I/O, plus an optional SQLAlchemy integration layer ported from aiopg. The primary programmatic entry points are `aiomysql.connect()` and `aiomysql.create_pool()`, which produce `Connection` and `Pool` objects used through `connection.cursor()`, `cursor.execute()`, and async context managers. A secondary entry point is `aiomysql.sa.create_engine()`, which wraps async pools with a SQLAlchemy engine/dialect facade for expression-based queries. The library implements MySQL protocol packet handling, authentication plugins, TLS, `LOAD DATA LOCAL INFILE`, server-side cursors, and result-set decoding. It has no web endpoints, CLI, or data pipelines; it is a dependency library, not an end-user application.

RATING: 7.8/10 MAINT: active DRIFT: medium
β–Έ 3 reusable components found
yuelinou999/idempotent-pipeline-demo β˜… 347 0 APPLICATION

This repository is a FastAPI + async SQLAlchemy reference implementation of an idempotent enterprise integration pipeline, explicitly labeled demo-grade rather than a production platform. Operators interact through REST endpoints covering idempotent message ingestion (five-branch deduplication: accept_new, accept_supersede, skip_duplicate, skip_stale, quarantine), simulated downstream delivery with retry classification, per-system circuit breakers, dead-letter queues, ambiguous-timeout handling with query-before-retry, audited operator replay, end-to-end record inspection, a dashboard health overview, and materialization/compaction jobs. Data flows from an ingestion write path through staging and production projections, then into delivery attempt logs, DLQs, ambiguous outcome queues, replay requests, and audit tables, with SQLite as the default database and PostgreSQL supported via a single environment variable change. The architecture is cleanly layered into routes, services, models, and schemas, with explicit bounded contexts for ingestion correctness, delivery resilience, and explainability. Seeded mock downstream systems make all delivery outcomes deterministic, which is appropriate for a demo harness. The codebase demonstrates good engineering practices: pure decision functions separated from DB side effects, flush-but-don't-commit transaction boundaries, append-only audit logs, and a comprehensive pytest suite covering scenario-based integration and unit tests. Notable caveats include placeholder rule-based correlation matching, some dead/duplicated schema definitions, a version mismatch between pyproject.toml (0.1.0) and the FastAPI app (0.7.0), and an unusual pyproject build-backend string that may break pip package builds. The repository appears maintained as of September 2026 with five open issues and modern dependency ranges. Technical drift is low: SQLAlchemy 2.0 async mappings, Pydantic v2, and current FastAPI patterns are used. While the application is not production-ready itself, several of its pure service modules are genuinely reusable building blocks for idempotency, retry, and correlation problems in other integration systems.

RATING: 7.5/10 MAINT: maintained DRIFT: low
β–Έ 5 reusable components found
── end of results ──
$ submit: