Skip to content

Validate driverless capability and fall back to manual driver selection - #469

Merged
alexpevzner merged 13 commits into
masterfrom
optimize-driverless-ipp-path
Sep 22, 2026
Merged

alexpevzner merged 13 commits into
masterfrom
optimize-driverless-ipp-path

Conversation

@SinghCod3r

@SinghCod3r SinghCod3r commented Sep 18, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Test whether a printer's advertised driverless IPP support actually works before using the driverless mode.

If the driverless PPD can be successfully generated and opened, the printer continues through the driverless setup path. If the driverless PPD cannot be used, system-config-printer abandons driverless mode and falls back to the legacy driver-selection workflow.

This handles printers that advertise driverless support but have broken or incompatible driverless implementations.

What changed

  • Probe the driver's driverless PPD before selecting driverless mode.
  • If validation succeeds, continue with driverless setup.
  • If validation fails:
    • disable driverless mode for that printer;
    • prevent the broken driverless: PPD from being selected again;
    • fall back to the existing manual driver-selection workflow;
    • load the local CUPS PPD catalog for Make/Model selection;
    • avoid unnecessary PackageKit and OpenPrinting searches for a printer that has already failed the driverless probe.
  • Distinguish IPP and IPP over USB in the Connection section using the existing dnssdresolve.is_ipp_over_usb_device() helper.

Testing

Broken Xerox B235

Verified with the Broken Xerox B235 simulator that:

  1. The printer advertises driverless IPP support.
  2. Driverless PPD validation fails.
  3. Driverless mode is abandoned.
  4. The broken driverless PPD is not selected again.
  5. The local CUPS PPD catalog is loaded.
  6. The workflow reaches the manual Make/Model driver-selection page.
  7. PackageKit and OpenPrinting are not queried after the failed driverless probe.

Working driverless printer

Verified that a printer with a valid driverless PPD continues through the driverless setup path.

Automated tests

  • python3 -m pytest test_newprinter.py — 34 passed
  • python3 -m pytest test_newprinter.py test_dnssdresolve.py test_PhysicalDevice.py — 50 passed
  • git diff --check — clean

Future work

Optimizing the successful driverless path to avoid unnecessary PPD catalog loading can be addressed separately.

@SinghCod3r SinghCod3r changed the title Optimize driverless IPP setup by skipping PPD catalog loading Validate driverless capability and fall back to manual driver selection Sep 22, 2026
@alexpevzner
alexpevzner merged commit 229a36d into master Sep 22, 2026
5 checks passed
@alexpevzner
alexpevzner deleted the optimize-driverless-ipp-path branch September 24, 2026 07:18
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