Skip to main content

django-copyist

Tool for precise and efficient copying of Django models instances.

Do you live in fear of the day when PM will come to you and ask to implement a copy feature for your root model, that has a lot of relations and you know that it will be a pain to implement it in a way that will work properly?

Well, fear no more, as django-copyist got you covered

Features

  • Precision - Copy only what you need in a way that you need with help of custom copy actions.

  • Readability - With declarative style config - you can easily see what and how is copied, no need to hop between models and parse it in your head.

  • Efficiency - Unlike some other solutions and naive approaches, copyist is copying your data without recursive hopping between model instances, which gives it a magnitudes of speedup on big data sets.

  • Flexibility - Copyist covers all steps that are there for data copy, including validation of data, pre-copy and post-copy actions. Copyist also work good with de-normalized data, not judging you for your choices.

  • Interactive - Copyist provides a way to interact with the copy process, allowing application to see what exactly is going to be done, and propagate that info to end user to decide if he wants to go through with it.

  • Reusability - With copyist your copy flow is not nailed down to model, allowing you defining different approaches for same model, and at the same time reuse existing configurations.

Motivation

This project was build as in-house tool for project with complex hierarchy of models, where we needed to copy them in a very particular way.

Existing solutions like django-clone were designed in a way that didn’t fit our needs, as they required to modify models and didn’t allow to have full control over the copying process.

This project aims to provide a more flexible and efficient way to copy Django models instances, while not affecting existing codebase.

Quickstart

This pages aims to get you going with django-copyist as quickly as possible.

Installation

To install with pip:

pip install django-copyist

To install with poetry:

poetry add django-copyist

Usage

See quickstart in docs

Metadata

Release files for django-copyist 0.1.3

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-copyist 0.1.3
File Size Uploaded Provenance Actions
django_copyist-0.1.3.tar.gz 19.5 kB Without provenance Details for django_copyist-0.1.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for django-copyist 0.1.3
File Interpreter ABI Platform Actions
django_copyist-0.1.3-py3-none-any.whl Python 3 none any Details for django_copyist-0.1.3-py3-none-any.whl

Total release size: 41.1 kB

Release files / django_copyist-0.1.3.tar.gz

Download URL django_copyist-0.1.3.tar.gz
Size 19.5 kB
Tags Source
SHA-256 checksum
How to use checksums
e462fc468562341789d5bdca5179e371da821a4fd5cc4e4b3ef93b8691b03f89
BLAKE2b-256 checksum
How to use checksums
7c19c1359eb8f0e26e536c35934dcafc74d676c04da191ffcff43c7429efc542
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.12.3

Release files / django_copyist-0.1.3-py3-none-any.whl

Download URL django_copyist-0.1.3-py3-none-any.whl
Size 21.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b3a4e465db650279c215a0df8747a67d578bebf087f83c5b2094e5c512217fab
BLAKE2b-256 checksum
How to use checksums
c8a793d561b719d3b38b86cc7a5faad836b57be0cdba4d972a16458580d76b2a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.12.3

Security for django-copyist 0.1.3

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.

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