Skip to main content

Hardcharger™

PyPI Downloads PyPI: hardcharger PyPI: adbc-driver-hardcharger Hardcharger Warp SQL protocol Apache 2.0 license GizmoData

hardcharger

Run Hardcharger, GizmoData's DuckDB 2.0 server, from Python. The package has no dependencies: on first use it downloads the hardcharger-server release for your platform (Linux x86-64 and arm64, macOS on Apple silicon), checks it, caches it, and runs it as a subprocess. That makes a real server one line away in tests, notebooks and scripts.

Python package 2.0.1 downloads Hardcharger server 2.0.0 by default.

Package What it is
pip install hardcharger this package: the server
pip install adbc-driver-hardcharger the client, an ADBC/DB-API driver
pip install "hardcharger[adbc]" both, so Server.connect() returns a connection

Quick start

import hardcharger

with hardcharger.Server() as server, server.connect() as conn, conn.cursor() as cur:
    cur.execute(operation="SELECT 42 AS answer, HARDCHARGER_VERSION() AS version")
    print(cur.fetch_arrow_table())

Server() listens on a free port on 127.0.0.1, with an in-memory database and an administrator hardcharger whose password it generates (server.password). The credentials reach the server through its environment, so they don't show in ps.

Hand the server to any other client by its URI:

import hardcharger

with hardcharger.Server(database="analytics.duckdb", password="change-me") as server:
    print(server.uri)  # hardcharger://127.0.0.1:<port>?tls=false
    print(server.username, server.port, server.health_port)

TLS is tls_cert= and tls_key= (the URI drops ?tls=false, and connect() trusts that certificate); any other server option goes in extra_args=[...] or, as HARDCHARGER_* variables, in env={...}. hardcharger-server --help lists them all.

The command line

The package also installs hardcharger-server, which runs the downloaded server:

$ hardcharger-server --version
Hardcharger 0.3.0
$ python -m hardcharger download       # download (if needed) and print the binary's path
/home/me/.cache/hardcharger/v0.3.0/linux-amd64/bin/hardcharger-server

The download

The release comes from gizmodata/hardcharger through the GitHub API. Its SHA-256 must match the digest GitHub recorded for the asset, and the unpacked server must report the expected version, or nothing is installed.

Public releases download anonymously. An optional GitHub token raises the API rate limit: HARDCHARGER_INSTALL_TOKEN, else GH_TOKEN, else the token of a signed-in gh (gh auth token). Set HARDCHARGER_INSTALL_TOKEN=none to force an anonymous download. The token is sent only to the GitHub API, never to the storage host the download is redirected to, and is never printed.

Variable Meaning
HARDCHARGER_SERVER_BINARY run this hardcharger-server instead of downloading one
HARDCHARGER_VERSION the server version to download (default: the one this package pins)
HARDCHARGER_CACHE_DIR where downloads are kept (default ~/.cache/hardcharger)
HARDCHARGER_INSTALL_TOKEN the GitHub token for the download (none: anonymous)

Tests

uv venv && uv pip install -e . --group dev
.venv/bin/python -m pytest -m "not integration and not download"      # no server needed
HARDCHARGER_PY_TEST_SERVER_BINARY=/path/to/hardcharger-server \
  .venv/bin/python -m pytest -m "integration and not client"           # the real server
.venv/bin/python -m pytest -m download                                 # a real download

The client tests also need adbc-driver-hardcharger installed. The integration, client and download tests fail, never skip, without their server, client or GitHub access.

License

Apache License 2.0.

This package is Python only and contains no third-party code. The hardcharger-server it downloads does: its release archive's THIRD_PARTY_NOTICES.md and THIRD_PARTY_NOTICES-web-ui.txt, which the install keeps beside bin/ (~/.cache/hardcharger/v<version>/<platform>/), list that software and its licences, and hardcharger-server --licenses prints them.


Built by GizmoData

Metadata

Release files for hardcharger 2.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for hardcharger 2.0.1
File Size Uploaded Provenance
hardcharger-2.0.1.tar.gz 20.6 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for hardcharger 2.0.1
File Interpreter ABI Platform
hardcharger-2.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 34.5 kB

Release files / hardcharger-2.0.1.tar.gz

Download URL hardcharger-2.0.1.tar.gz
Size 20.6 kB
Tags Source
SHA-256 checksum
How to use checksums
d552a2e86d99317cc10f73f2565f29df847175acf29f2dcd906a1d00d298317e
BLAKE2b-256 checksum
How to use checksums
27b407ff2cacffd3defd7680e88c812d3d3bc021b89ed8a772a1b5af36754f5d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Release files / hardcharger-2.0.1-py3-none-any.whl

Download URL hardcharger-2.0.1-py3-none-any.whl
Size 13.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
15d579f5a4aa223d9346b35e2a7c38525a176808e250d47e39ef3db7ef8b8a51
BLAKE2b-256 checksum
How to use checksums
9bd3f3cc2c50eb63d754781718794a10c4e871a89910abaa7e122251d53d4f86
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

Security for hardcharger 2.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for hardcharger-2.0.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 22, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page