Skip to content

qvm-device: fix wrappers on Python 3.14 - #500

Open
mickeyslaven wants to merge 1 commit into
QubesOS:mainfrom
mickeyslaven:fix-11029-python314-device-parser
Open

mickeyslaven wants to merge 1 commit into
QubesOS:mainfrom
mickeyslaven:fix-11029-python314-device-parser

Conversation

@mickeyslaven

Copy link
Copy Markdown

Python 3.14 rejects store_const on positional arguments, preventing qvm-block, qvm-usb, and qvm-pci from constructing their parsers.

The fix uses a parser default for the wrapper provided device class and add a regression test for fixed-class parsers. This method was suggested by the initial issue contributor.

Fixes QubesOS/qubes-issues#11029

AI DISCLOSURE: Generative Ai was utilized in testing, writing, and assisting in review of this code. I signed and personally reviewed the code myself and take responsibility for its contents.

Python 3.14 rejects store_const on positional arguments, preventing
qvm-block, qvm-usb, and qvm-pci from constructing their parsers.

Use a parser default for the wrapper-provided device class and add a
regression test for fixed-class parsers.

Fixes QubesOS/qubes-issues#11029
@codecov

codecov Bot commented Aug 29, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 76.87%. Comparing base (610a6f1) to head (f75aac4).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #500      +/-   ##
==========================================
+ Coverage   76.85%   76.87%   +0.01%     
==========================================
  Files          53       53              
  Lines        9438     9438              
==========================================
+ Hits         7254     7255       +1     
+ Misses       2184     2183       -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.

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.

qvm-block/qvm-usb/qvm-pci crash on Python 3.14: "action 'store_const' is not valid for positional arguments"

1 participant