本地测试吉诃德模型的脚本

dulcinee的Python项目详细描述


杜尔西尼亚

允许在本地测试吉诃德模型的脚本。

安装

pip install -r requirements.txt

如何使用Dulcinea

usage:dulcinea.py[-h]-cCONFIG_FILE-iINFO_FILE[-rROOT_DIR]moulinette_directorypositionalarguments:moulinette_directoryoptionalarguments:-h,--helpshowthishelpmessageandexit-cCONFIG_FILE,--config-fileCONFIG_FILEjsonfilecontainingtheuserinformations-iINFO_FILE,--info-fileINFO_FILEjsonfilecontainingtheinformationofthejobstoexecute-rROOT_DIR,--root-dirROOT_DIRdirectorywherethejobswillbeexecuted

conf文件示例

conf文件必须使用-c选项给出,并且包含要插入到上下文中的有用元数据,如用户信息

{"intra_user":"login_z","intra_password":"superPassSecure","gitlab_token":"superCuteToken"}

蓝图

为了在本地测试moulinette,脚本必须能够获取一些要测试的虚拟传递。

通常,这是通过使用内置的fetch.copy将获取步骤替换为“本地”获取来实现的:

importquixote.fetch.copyasfetch@quixote.fetcherdeffetch_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.

信息文件示例

信息文件必须使用-i选项给出,并且应该包含所有虚拟传递的元数据。

[
    {
        "module_id": 1,
        "activity_id": 1,
        "group_id": 1
    },
    {
        "module_id": 1,
        "activity_id": 1,
        "group_id": 2
    }
]

The values for module_id and activity_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.

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
正在用户处创建的java文件。在Ubuntu中使用home而不是相对路径   使用Java查找数组中3的最后倍数   java SimpleDataFormat。解析(日期\字符串)生成上一个日期   如何在Java项目中使用Android的LogCat?   java Basic swing ui在默认值之外的其他“main”方法中使用   java如何设置log4j的最大文件大小不受限制?   摇摆Java框架游戏   用Java DOM解析XML文件   java获取素数   java什么是最好的UI元素拖动算法   java十进制到二进制转换器循环   java可以为同一个项目创建多个jar文件吗   JavaZK将组件添加到特定页面