Django app to support ltree postgres extension
Project description
django-ltree
An tree extension implementation to support hierarchical tree-like data in Django models,
using the native Postgres extension ltree
.
Postgresql has already a optimized and very useful tree implementation for data. The extension is ltree
This fork contains a backport to Django 1.11 and Python 2.7.
Links
- Pypi https://pypi-hypernode.com/project/django-ltree/
- Source code https://github.com/mariocesar/django-ltree
- Bugs https://github.com/mariocesar/django-ltree/issues
- Contribute https://github.com/mariocesar/django-ltree/pulls
- Documentation
TODO
Install
pip install django-ltree
Then add django_ltree
to INSTALLED_APPS
in your Django project settings.
And make sure to run django_ltree
migrations before you added the PathField
python manage.py migrate django_ltree
django_ltree
migrations will install the ltree
extension if not exist.
You can alternatively specify the django_ltree
dependency in the migrations of
your applications that requires PathField
, and run migrations smoothly.
class Migration(migrations.Migration):
dependencies = [
('django_ltree', '__latest__'),
]
Requires
- Django 1.11 or superior
- Python 2
Testing
Make sure you have Postgres installed. Then simply run tox
in the root directory of the project.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file django_ltree-0.5.tar.gz
.
File metadata
- Download URL: django_ltree-0.5.tar.gz
- Upload date:
- Size: 6.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.8.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 22fac147c3f6f113fa0f404c8f6d84057eb16ddebf71cd57c2aebf725964c661 |
|
MD5 | f89a682aa2ebeb55bbb99439324b60b5 |
|
BLAKE2b-256 | 23e599be47f9412c6c5910213b89fd35eda5f9d3ba02a9e7ce1a8d3603b6c082 |
File details
Details for the file django_ltree-0.5-py2.py3-none-any.whl
.
File metadata
- Download URL: django_ltree-0.5-py2.py3-none-any.whl
- Upload date:
- Size: 8.2 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.8.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 290faf9f3e73ed9136083a4ee66cfc29229eca1cadb94484e6455f0600651148 |
|
MD5 | 4f607e7eee077f3a55bc20c78197b044 |
|
BLAKE2b-256 | 46eb2d87f36efb16850864896a206eca7393c0507a58ac33657c0b008b7b00f4 |