openzim / openzim/cms

Better handling of flavours transitions

Open
#529 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Python
Stars
7
Forks
1
Avg merge
15h 20m
Merged PRs (30d)
18

Description

CMS tooling to handling transition of flavours in a given recipe is not sufficient.

For instance with https://farm.openzim.org/recipes/wikiquote_tr/history?compare=74060960-c97e-4787-baef-c9b33639644c...83acfae3-cdfc-4ff6-a9fd-25a735dab41e the wikiquote_tr recipe changed from producing mini + maxi flavours to producing only the empty (soon full) flavour.

When this recipe runs again, the CMS receives a new book without a flavour not yet declared on the CMS title. The CMS editor hence has to acknowledge that this is an expected new flavour. This is OK.

The problem is that the CMS editor would like to say at the same moment that mini and maxi flavours should not be published anymore. This is not possible. It is possible to fully delete these flavours (which in turns delete the book) but I don't feel like this is what we wanna do. We should probably rather remove mini and maxi from the catalog(s) but keep files on the FS (to keep ongoing downloads working fine, and to keep a previous version as usual), and then once we have two books with the target flavours we can delete the old ones.

This process is maybe to complex to fully automate, but if we agree this is what we wanna do we can discuss potential implementation (maybe simply being able to hide a flavour from the catalog is sufficient and the rest can be handled by humans clicks).

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing how the CMS handles a recipe run that introduces a new flavour and how flavour visibility in catalogs is represented. Review the relevant CMS entry points for catalog publication and filesystem retention; done should allow old flavours to be hidden from catalogs while keeping their files available until the replacement flavours are established.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.