No project description provided
Project description
OARepo model builder requests
Plugin ("wrapper") for oarepo-model-builder to allow specifying requests
tied to the model.
Requests are requests for an action concerning an instance of the model (called topic), for example to publish the topic.
Applicable requests can be added to the model through "requests" section in the yaml file of the model. There can be any number of them.
Options:
- "action-class": Specify class for the accept action done by the request. By default, a template action class which fetches the topic and saves it is generated. The action done on the topic has to be defined by the user.
- "action-class-name": Specify the name of the generated template action class. If not specified, request name in camel case + "AcceptAction" is used.
- "action-class-bases": Specify the base classes from which the generated template action classes inherits. By default it's [invenio_requests.customizations.AcceptAction].
- "generate-action-class": Tell the model builder whether it should generate the accept action class templete. True by default.
- RequestType allows the same customizations, the name of the properties are analogical after replacing "action" with "type".
See model_requested_document.yaml in tests for usage example. What is done with the topic if the template accept action class is generated has to be specified manually in the requests/actions.py file.
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
Close
Hashes for oarepo-model-builder-requests-2.0.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | b4aec69e081eb9adc7e77a20fb5ef6f32145f5e822ceb45f06505dc9262dd619 |
|
MD5 | 85d4fef6755c2b9e39c1c719be76a69c |
|
BLAKE2b-256 | 96cc358d29e267f4be95ec9b71007f79126cb4079d865dc42d3a3fc9533c1350 |
Close
Hashes for oarepo_model_builder_requests-2.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f86d1eae6be3dd6191091f89cb4d85c4656a9e1d9a2ab9e2c4581578adf81c5d |
|
MD5 | 6f1409c37bc568996f2907b70234496d |
|
BLAKE2b-256 | 8ff29348041af7099063fe94b335494a51b1b533ae3857227d9e32183afcf438 |