Skip to main content
https://img.shields.io/github/actions/workflow/status/adamchainz/django-harlequin/main.yml.svg?branch=main&style=for-the-badge https://img.shields.io/badge/Coverage-100%25-success?style=for-the-badge https://img.shields.io/pypi/v/django-harlequin.svg?style=for-the-badge https://img.shields.io/badge/code%20style-black-000000.svg?style=for-the-badge pre-commit

Launch Harlequin, the SQL IDE for your Terminal, with your Django database configuration.


Work smarter and faster with my book Boost Your Django DX which covers many tools to improve your development experience.


Requirements

Python 3.9 to 3.13 supported.

Django 4.2 to 5.2 supported.

Supported database backends: MariaDB/MySQL, PostgreSQL, SQLite.

Installation

First, install with pip:

python -m pip install django-harlequin

Second, install Harlequin with appropriate Harlequin adapter packages for the database backends you use. For example, to install Harlequin with the PostgreSQL adapter:

python -m pip install 'harlequin[postgres]'

Harlequin does not need to be installed in the same virtual environment as Django, as django-harlequin does not import it. You only need the harlequin command on your path, so you can install Harlequin globally, or in an isolated virtual environment with a tool like pipx.

Third, add the app to your INSTALLED_APPS setting:

INSTALLED_APPS = [
    ...,
    "django_harlequin",
    ...,
]

Usage

harlequin command

Run the harlequin management command to launch Harlequin, connected to your default database:

$ ./manage.py harlequin

Pass --database to select a different database connection from settings.DATABASES:

$ ./manage.py harlequin --database replica

Extra options, optionally after a -- delimiter, will be passed through to Harlequin. For example, to read its help page, as opposed to that of the management command:

$ ./manage.py harlequin -- --help

Configuration

Harlequin automatically loads configuration from pyproject.toml or its own files within the current working directory, which would mean next to your manage.py file. See Harlequin’s configuration documentation for details on the available options.

Metadata

Release files for django-harlequin 1.5.0

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

Source distribution (sdist)

Source distribution for django-harlequin 1.5.0
File Size Uploaded
django_harlequin-1.5.0.tar.gz 7.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for django-harlequin 1.5.0
File Interpreter ABI Platform
django_harlequin-1.5.0-py3-none-any.whl Python 3 none any Details

Total release size: 13.0 kB

Release files / django_harlequin-1.5.0.tar.gz

Download URL django_harlequin-1.5.0.tar.gz
Size 7.2 kB
Tags Source
SHA-256 checksum
How to use checksums
b761fa158b4833e6ac03b1926e0ec217a90a364d683af28228c786e04c1bc219
BLAKE2b-256 checksum
How to use checksums
a94935a2dd00a6859083bb5bea6602b9aa7a78a11ae9fbbb5a7715793ca24805
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.8

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 Feb 6, 2025.

Transparency log

Release files / django_harlequin-1.5.0-py3-none-any.whl

Download URL django_harlequin-1.5.0-py3-none-any.whl
Size 5.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
31afff3c6560738907693d8f0bba70e0bba0041db26b32c51a5c61cf104a6b38
BLAKE2b-256 checksum
How to use checksums
8b8299610792b5dba62f748b8a7a16ad699490c211d0cd3b627e62215093b216
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.8

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 Feb 6, 2025.

Transparency log

Release history Release notifications | RSS feed

1.7.0

2 release files

1.6.0

2 release files

This release

1.5.0 This release

2 release files

1.4.0

2 release files

1.3.0

2 release files

1.2.0

2 release files

1.1.2

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.0

2 release files

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