Bug 15388

Summary: Pagination needs to be rewritten (e.g. Machine -> Browse isn't paginated)
Product: [Yocto Project Subprojects] Layer Index Reporter: Ross Burton <ross.burton>
Component: Layer IndexAssignee: Piotr Buliński <piotr>
Status: RESOLVED FIXED QA Contact: apoorv sangal <apoorvsangal>
Severity: normal    
Priority: Medium+ CC: randy.macleod, tim.orling, william.lyu
Version: unspecified   
Target Milestone: Future   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description Ross Burton 2024-02-07 18:09:32 UTC
If I click Machines -> Browse and end up at https://layers.openembedded.org/layerindex/branch/master/machines/?q=&browse=1, I only see machines that start with 'a' because the list isn't paginated.
Comment 1 Tim Orling 2024-02-08 16:05:45 UTC
We had to disable the existing pagination in:

e86a2c2 "Drop django-bootstrap-pagination: incompatible"
bd58fbe "bootstrap_pagination: disable via comment"

because https://pypi.org/project/django-bootstrap-pagination/ is not compatible with Django 3+ (and definitely not with Django 4+).

It was added in:
f527692 "Replace custom pagination with django-bootstrap-pagination"
but the prior code is probably also not what we want to do.

The code (templates/layerindex/machines.html and friends) will have to be rewritten.

A possible replacement candidate is concerning because it is marked as wanting a maintainer:
https://pypi.org/project/django-pagination-bootstrap/

Pagination was also added to Django itself, so perhaps we are better off using that and not being beholden to third party plugins:

https://docs.djangoproject.com/en/4.2/topics/pagination/

Related? Moving to newer bootstrap versions is also very tricky... updating to bootstrap4 was attempted but RRS was very hard to ferret out and bootstrap5 which dropped jquery usage, which is a major change.
Comment 2 Tim Orling 2026-01-16 19:53:38 UTC
As discussed with Piotr, transfering ownership for this bug.
Comment 3 Piotr Buliński 2026-01-31 14:36:47 UTC
Patch https://lists.yoctoproject.org/g/yocto-patches/message/3155