Skip to content

Commit

Permalink
Merge pull request #935 from openzim/fix_zimit_keep
Browse files Browse the repository at this point in the history
Zimit keep flag was set but not declared in Offliner definition
  • Loading branch information
benoit74 authored Mar 5, 2024
2 parents f1f2327 + 72b53c4 commit 05fb9cd
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
11 changes: 11 additions & 0 deletions dispatcher/backend/src/common/schemas/offliners/zimit.py
Original file line number Diff line number Diff line change
Expand Up @@ -432,6 +432,17 @@ class Meta:
required=False,
)

keep = fields.Boolean(
truthy=[True],
falsy=[False],
metadata={
"label": "Keep",
"description": "Should be True. Developer option: must be True if we want "
"to keep the WARC files for artifacts archiving.",
},
required=False,
)

output = String(
metadata={
"label": "Output folder",
Expand Down
4 changes: 3 additions & 1 deletion dispatcher/backend/src/utils/offliners.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,9 @@ def command_for(offliner, flags, mount_point):
if offliner == Offliner.zimit:
if "adminEmail" not in flags:
flags["adminEmail"] = "[email protected]"
flags["keep"] = True # always keep temporary files, they will be deleted anyway
if "keep" not in flags:
# always keep temporary files, they will be deleted anyway
flags["keep"] = True

_command_for_set_default_publisher(flags, offliner_def)

Expand Down

0 comments on commit 05fb9cd

Please sign in to comment.