Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Common constraint: filename format #9

Open
kelson42 opened this issue May 20, 2021 · 6 comments
Open

Common constraint: filename format #9

kelson42 opened this issue May 20, 2021 · 6 comments
Labels
enhancement New feature or request stale
Milestone

Comments

@kelson42
Copy link
Contributor

Should match something like /^(.+?_)([a-z\-]{2,10}?_|)(.+_|)([\d]{4}|)\-([\d]{2})$/i

@kelson42 kelson42 added the enhancement New feature or request label May 20, 2021
@kelson42 kelson42 changed the title ZIM file format should be checked ZIM filename format should be checked Jun 2, 2021
@stale
Copy link

stale bot commented Aug 2, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be now be reviewed manually. Thank you for your contributions.

@stale stale bot added the stale label Aug 2, 2021
@rgaudin rgaudin changed the title ZIM filename format should be checked Common constraint: filename format Oct 19, 2021
@stale stale bot removed the stale label Oct 19, 2021
@kelson42
Copy link
Contributor Author

kelson42 commented Jan 1, 2022

To avoid problems like kiwix/container-images#198

@kelson42 kelson42 added this to the M2 milestone Jan 1, 2022
@rgaudin
Copy link
Member

rgaudin commented Jan 3, 2022

Given filename is not something we'll have control over, am I right to assume an invalid filename should prevent Book creation on the add_book endpoint?

@kelson42
Copy link
Contributor Author

kelson42 commented Jan 3, 2022

I'm not 100% sure about the exact behaviour of the CMS in that case but what is sure is that:

  • The file should not be published
  • This is an error which should be handled manually in a similar manner like if the zimcheck results would not pass the threshold.

@rgaudin
Copy link
Member

rgaudin commented Jan 3, 2022

OK, we'll discuss this again when working on M2 then.

@stale
Copy link

stale bot commented Apr 16, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be now be reviewed manually. Thank you for your contributions.

@stale stale bot added the stale label Apr 16, 2022
@rgaudin rgaudin modified the milestones: M2, M3 May 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request stale
Projects
None yet
Development

No branches or pull requests

2 participants