Script to test Quixote moulinettes locally
Project description
Dulcinea
Script allowing to test Quixote moulinettes locally.
Install
pip install -r requirements.txt
How to use dulcinea
usage: dulcinea.py [-h] -c CONFIG_FILE -i INFO_FILE [-r ROOT_DIR] moulinette_directory
positional arguments:
moulinette_directory
optional arguments:
-h, --help show this help message and exit
-c CONFIG_FILE, --config-file CONFIG_FILE json file containing the user informations
-i INFO_FILE, --info-file INFO_FILE json file containing the information of the jobs to execute
-r ROOT_DIR, --root-dir ROOT_DIR directory where the jobs will be executed
Conf file example
The conf file must be given using the -c
option and contain usefull meta-data to insert in the context such as the user's information
{
"intra_user": "login_z",
"intra_password": "superPassSecure",
"gitlab_token": "superCuteToken"
}
Blueprint
In order to test the moulinette locally, the script must be able to fetch some dummy delivery to test.
Usually, it is achieved by replacing the fetching step with a "local" fetch using the fetch.copy
built-in:
import quixote.fetch.copy as fetch
@quixote.fetcher
def fetch_by_copying():
fetch.copy(path_to_the_dummy_delivery_folder)
The dummy delivery folder must contain a directory for each group_id specified in the info file which will act as dummy delivery for the specific job. See the documentation for
fetch.copy
.
Info file example
The info file must be given using the -i
option and should contain the meta-data of all dummy deliveries.
[
{
"module_id": 1,
"activity_id": 1,
"group_id": 1
},
{
"module_id": 1,
"activity_id": 1,
"group_id": 2
}
]
The values for
module_id
andactivity_id
don't really matter, they are just dummy values to insert into the context.group_id
however must match the directory name inside the dummy delivery folder.
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 Distributions
Built Distribution
Hashes for etna_dulcinea-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2faa677047f377117696adf9239ec60306ed2c3b3af530cbc6df8c33223d13e4 |
|
MD5 | b21b47bf9cc233e20041e3e836f2fe7f |
|
BLAKE2b-256 | c175c310e925385cf527e7ef442697599511a0fc14be6a0b8b37fae80963199d |