Extension for JSONPatch (RFC6902) that introduces operation preconditions, change tracking and automated listeners that can introduce new operations based on the previous change
Project description
JSONPatch-Trigger
This package extends the JSON Patch (RFC 6902) functionality with the following features:
- Preconditions for operations that prevent their execution
- Usage of JSONPaths over JSONPointers to allow operation targets with wildcards and conditions
- Change tracking of each operation (a list of additionas and deletions as JSONPointers)
- Listeners that can react to the tracked changes to dynamically perform customizable actions when something in the JSON document has changed
The JSONPath and JSONPatch implementations used as a basis are from https://pypi.org/project/python-jsonpath/
Use Case
The functionalities in this package have been developed to serve the following use case:
A process P produces JSON objects. Every time P executes the results needs to be adjusted with changes the user can configure. So the set of operations is persisted and applied for every process run. There are different processes and each requires a different set of user operations. Additionally, the produced JSON objects can have patterns that can be changed automatically instead of with a manual user action. However, the automated steps might be dependent on the order of user operations. So instead of appending or prepending the automated operations, a listener approach is used to apply the automated operation as soon as a certain path in the document is modified (triggered). For this to work properly the first operation is always an AddOperation that adds the entire existing object therefore the tracking produces an addition for every JSONPointer in the document.
CI Debug Counter
3
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file jsonpatch_trigger-0.2.0.tar.gz.
File metadata
- Download URL: jsonpatch_trigger-0.2.0.tar.gz
- Upload date:
- Size: 14.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
16107233e2199d74732af6b7afa1fe59150b229683172844905f9ae9e3d23886
|
|
| MD5 |
b44b14b361555be07576583c5ec322cc
|
|
| BLAKE2b-256 |
7eb9c2e3b03606ebe131f9a3f10d240d2b8f3526d4d56821f73329f1307e4ff3
|
Provenance
The following attestation bundles were made for jsonpatch_trigger-0.2.0.tar.gz:
Publisher:
ci.yaml on Cpprentice/jsonpatch-trigger
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
jsonpatch_trigger-0.2.0.tar.gz -
Subject digest:
16107233e2199d74732af6b7afa1fe59150b229683172844905f9ae9e3d23886 - Sigstore transparency entry: 1219973424
- Sigstore integration time:
-
Permalink:
Cpprentice/jsonpatch-trigger@e394e6d1fe6ba27afaa5baf71c9413330bc05554 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/Cpprentice
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
ci.yaml@e394e6d1fe6ba27afaa5baf71c9413330bc05554 -
Trigger Event:
push
-
Statement type:
File details
Details for the file jsonpatch_trigger-0.2.0-py3-none-any.whl.
File metadata
- Download URL: jsonpatch_trigger-0.2.0-py3-none-any.whl
- Upload date:
- Size: 14.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6002d7f8934c2ede0a85d5e7bc561954d814b0674cfd0394ba34855d030f2d3f
|
|
| MD5 |
f8f4a01b28b08f7c18959e2a6de831f5
|
|
| BLAKE2b-256 |
2aa97224b0d42f4ed05dbfb8de71094c1923b24587cbc624b9a270e33b49482c
|
Provenance
The following attestation bundles were made for jsonpatch_trigger-0.2.0-py3-none-any.whl:
Publisher:
ci.yaml on Cpprentice/jsonpatch-trigger
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
jsonpatch_trigger-0.2.0-py3-none-any.whl -
Subject digest:
6002d7f8934c2ede0a85d5e7bc561954d814b0674cfd0394ba34855d030f2d3f - Sigstore transparency entry: 1219973486
- Sigstore integration time:
-
Permalink:
Cpprentice/jsonpatch-trigger@e394e6d1fe6ba27afaa5baf71c9413330bc05554 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/Cpprentice
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
ci.yaml@e394e6d1fe6ba27afaa5baf71c9413330bc05554 -
Trigger Event:
push
-
Statement type: