Skip to content

list_all_packages suggests blank entries when dpkg-query output has trailing newline #380

Description

@vikvang

Description

The list_all_packages generator callback in command-signatures/src/generators/apt.rs pushes a suggestion for every line of output without filtering empty lines. Unlike list_available_packages (which guards with is_empty()), a trailing newline or blank line in dpkg-query output produces an empty suggestion in the completion list.

Where

command-signatures/src/generators/apt.rs — compare list_all_packages (no empty check) with list_available_packages (has the check). list_all_deb_files_in_cwd has the same gap.

Expected

Blank lines filtered out before creating suggestions, consistently across the three apt callbacks.

Impact

Cosmetic but user-visible: an empty row can appear in apt-get completions.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething is not working as expectedfactory:warp-for-ossOwned by the Warp for OSS factorygood first issueGood for newcomersrepro:highLooks highly reproducible from the available informationtriagedInitial factory triage has been completed

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions