Batch actions: fetch all pages when requesting locales from API - #4420
Conversation
Set page_size to the maximum to cover current and future locale counts
flodolo
left a comment
There was a problem hiding this comment.
While this fixes the immediate problem, we should make the code able to deal with paginated (it shouldn't require too much additional code).
I wasn't involved in the original implementation, but maybe we should also fetch the list of locales for the project we're in, and fall back to all locales? The copy only makes sense if the locale has translations, and that won't be possible if the locale is not available.
e.g. for Firefox use https://pontoon.mozilla.org/api/v2/projects/firefox/, for All projects use the current https://pontoon.mozilla.org/api/v2/locales/
Happy to keep the project-specific locales for a follow-up.
I'll add pagination and update the patch. Happy to file a separate issue for the project-specific locales after this PR is merged. |
|
@MundiaNderi Something like |
e97fc24 to
fb64d99
Compare
Codecov Report❌ Patch coverage is 🚀 New features to boost your workflow:
|
Fix #4419
Set page_size to the maximum(1000) to cover current and future locale counts.