Django Fast Generic Foreign Keys
Travis
Overview
Generic foreign keys are incredibly powerful but can’t be prefetched, leading to a large number of SQL queries when accessing a generic foreign key field while iterating over a queryset. This app provides a function that reduces the number of SQL queries to 1 + (number of content types included in the set of generic foreign keys).
Installation
Install or add django-fast-gfk to your Python path.
Usage
The fetch function returns a generator with the generic foreign key prefetched. Parameter field is the name of the generic foreign key.:
from fast_gfk import fetch fetch(Bar.objects.all(), field="target"))
Changelog
0.1
Initial release.
Metadata
Release files for django-fast-gfk 0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| django-fast-gfk-0.1.tar.gz | 4.8 kB | Without provenance | Details for django-fast-gfk-0.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| django_fast_gfk-0.1-py2.7.egg | Legacy Egg format | - | - | Details for django_fast_gfk-0.1-py2.7.egg |
Total release size: 14.1 kB
Release files / django-fast-gfk-0.1.tar.gz
| Download URL | django-fast-gfk-0.1.tar.gz |
|---|---|
| Size | 4.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
02bb720890527738d4f97950f8cd5196d8bc6e2fb3b7a99bf80e039998bba3a0
|
|
BLAKE2b-256 checksum How to use checksums |
1c504d26a1b876010ffef95396aa2a67dc26d7a0add895f06769c84f3c057c7a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / django_fast_gfk-0.1-py2.7.egg
| Download URL | django_fast_gfk-0.1-py2.7.egg |
|---|---|
| Size | 9.3 kB |
| Tags | Egg |
|
SHA-256 checksum How to use checksums |
fec7f550170c8923fa1a779ddfa3fbe1b058a9dce066bc0d668fabdc21902ff3
|
|
BLAKE2b-256 checksum How to use checksums |
c0038fd103706b416981e3db0e1f5e2c551572897bdc933726bc471203fe21f3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for django-fast-gfk 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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
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.