Skip to content

BUG: List the valid layouts in the page layout warning - #4010

Merged
stefan6419846 merged 1 commit into
py-pdf:mainfrom
RavSinghChandan:fix-layout-warning-message
Aug 25, 2026
Merged

stefan6419846 merged 1 commit into
py-pdf:mainfrom
RavSinghChandan:fix-layout-warning-message

Conversation

@RavSinghChandan

Copy link
Copy Markdown
Contributor

Setting an unknown page layout warns, but the message is not readable:

Layout should be one of: {'', '/NoLayout/SinglePage/OneColumn/TwoColumnLeft/TwoColumnRight/TwoPageLeft/TwoPageRight'}

It passes a set built from an empty string and the valid layouts joined without a separator, so the reader gets one run-on blob and a stray ''.

page_mode next to it already joins its values with a comma, so this brings the two in line:

Layout should be one of: /NoLayout, /SinglePage, /OneColumn, /TwoColumnLeft, /TwoColumnRight, /TwoPageLeft, /TwoPageRight

The warning passed a set built from an empty string and the valid layouts
joined without a separator, so it read

    Layout should be one of: {'', '/NoLayout/SinglePage/OneColumn/...'}

page_mode next to it already joins its values with a comma.
@codecov

codecov Bot commented Aug 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.00%. Comparing base (9344ad6) to head (699e49b).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4010      +/-   ##
==========================================
+ Coverage   97.98%   98.00%   +0.01%     
==========================================
  Files          57       57              
  Lines       11120    11120              
  Branches     2084     2084              
==========================================
+ Hits        10896    10898       +2     
+ Misses        125      124       -1     
+ Partials       99       98       -1     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@stefan6419846 stefan6419846 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@stefan6419846
stefan6419846 merged commit 29f389c into py-pdf:main Aug 25, 2026
20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants