Skip to content

PPF-2058: Preserve dropdown selection zero #2058

Closed

Description

@chinapandaman

Version

Reviewed baseline: PyPDFForm 6.0.0, commit 0b5cc1dc8604b36693864852d76ed7e60f903451.

Issue Description

At the reviewed snapshot, explicitly selecting dropdown index 0 yielded a live value of 0, then None after serialization and reopening. The read path must distinguish the first option from no selection. This issue addresses the zero-selection portion of R07.

Work

Replace truthiness-based handling of the selected index with an explicit distinction between zero and no selection in the dropdown read path.

Acceptance Criteria

  • Create → fill with index 0 → serialize → reopen returns 0, while an actually unselected field remains unselected. Include ordinary string options and the existing supported representation of empty values.

Basis and Dependencies

R07, a P1 finding. This is a separately useful repair; it does not resolve display/export conversion, which is E3-03.

Source and Validation

Action E1-05, Group 1 — Lowest-hanging fruit, from the October 10, 2026 action plan; supporting review evidence. Related action identifiers refer to that plan.

The behavior above is evidence from the source review, not a new reproduction performed when filing this issue. Reconfirm the relevant baseline or document intervening changes before implementation. Follow the plan's completion and validation rules and the Developer Guide, including meaningful regression assertions for behavior changes.

Activity

  1. changed the title [-]Preserve dropdown selection zero[/-] [+]PPF-2058: Preserve dropdown selection zero[/+] on Oct 11, 2026
  2. moved this from Backlog to In progress in PyPDFForm-support-2026on Oct 13, 2026
  3. moved this from In progress to In review in PyPDFForm-support-2026on Oct 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions