Skip to content

Page Order issues with CBZ files containing folders. #6642

Open
@jcc10

Description

@jcc10

This issue respects the following points:

  • This issue is not already reported on GitHub (I've searched it).
  • I agree to follow Jellyfin's Code of Conduct.
  • This report addresses only a single issue; If you encounter multiple issues, kindly create separate reports for each one.

Describe the bug

When a CBZ file that has folders containing images (a common method of handling chapters) the page Order is incorrect with the current order being used sorting at the file-name level then folder level (EG: c01/p01.png -> c02/p01.png -> c03/p01.png -> v01/p02.png) instead of sorting by absolute truncated name sequences.

Chrome and Firefox both preform different sorting to each other, but neither are the correct method.

  • Firefox sports in reverse chapter but correct page order.
  • Chrome sports in correct chapter and correct page order.
  • Both go through one page in each chapter before moving on to the next page, again in each chapter.

Reproduction Steps

  1. Download the following file: TestCBZ.zip
  2. Rename from TestCBZ.zip to TestCBZ.cbz and upload to Jellyfin in a book library.
  3. Attempt to view the book in the web-viewer
  4. Page through the book in Chrome or Firefox
  5. Note that you are moving through chapters then moving to then to the next page number.

Expected/Actual behaviour

Intended behavior is as follows:

  1. Sort the level you are at in alphabetical order
  2. Select the first item.
  3. If a folder, open the folder and repeat from step 1 at the new level
  4. If an image, display the image.
  5. If there is another file at the folder-level, repeat from step 3
  6. If there is not another file, exit the folder and resume the parent level of recursion.
  7. If there are no higher levels of recursion, you have finished the file.

Logs

This is a logic / sort issue, as such there are no log errors available.

Server version

10.10.6

Web version

10.10.6

Build version

10.10.6

Platform

Chrome OS, Windows 10

Browser

Chrome, Chrome & Firefox

Additional information

I'll also be adding an issue regarding chapter support in CBZ files momentarily. It may be worthwhile to add in chapter support for CBZ files at the same time as they can naively be defined as the first image in a folder.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions