Bug 442571

Summary: kdeconnect-cli -a lists not paired devices
Product: [Applications] kdeconnect Reporter: Andrei <tdhj744ra03u>
Component: commonAssignee: Albert Vaca Cintora <albertvaka>
Status: RESOLVED FIXED    
Severity: normal CC: adam.m.fontenot+kde, bsikka100
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Other   
Latest Commit: Version Fixed/Implemented In: 22.08
Sentry Crash Report:

Description Andrei 2021-09-17 01:55:17 UTC
SUMMARY
kdeconnect-cli --help says:
-a, --list-available          List available (paired and reachable) devices

Instead, it also lists reachable not paired devices, see https://invent.kde.org/network/kdeconnect-kde/-/blob/master/cli/kdeconnect-cli.cpp#L91

STEPS TO REPRODUCE
1. Have 2 reachable devices, one paired and one not
2. kdeconnect-cli -a

OBSERVED RESULT
Both devices are shown

EXPECTED RESULT
Only reachable AND paired device should be shown

SOFTWARE/OS VERSIONS
Linux: Ubuntu 21.04, kernel 5.11.0-31-generic
KDE Plasma Version: 5.21.4
KDE Frameworks Version: 5.80.0
Qt Version: 5.15.2
Comment 1 Adam Fontenot 2022-07-06 10:14:42 UTC
I encountered this as well, pretty easy to verify that this is what the code does. I'll try to submit a patch for this soon.
Comment 2 Bug Janitor Service 2022-07-06 10:58:45 UTC
A possibly relevant merge request was started @ https://invent.kde.org/network/kdeconnect-kde/-/merge_requests/479