Bug 389052 - Desired connections run away just before clicking the "connect" button or entering password
Summary: Desired connections run away just before clicking the "connect" button or ent...
Status: RESOLVED FIXED
Alias: None
Product: plasma-nm
Classification: Plasma
Component: applet (show other bugs)
Version: 5.25.5
Platform: Debian unstable Linux
: VHI grave
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords: usability
: 398291 401816 419288 424951 427512 427798 428304 429363 435430 442749 447397 449666 453598 459604 (view as bug list)
Depends on:
Blocks:
 
Reported: 2018-01-16 12:46 UTC by Josef Kufner
Modified: 2022-10-04 12:06 UTC (History)
20 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.26


Attachments
nm-applet before and after update (147.94 KB, image/png)
2020-11-02 10:07 UTC, Dan Snis
Details
attachment-30706-0.html (1.14 KB, text/html)
2020-12-24 16:59 UTC, Boris
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Josef Kufner 2018-01-16 12:46:07 UTC
When I open the network applet, I can see the list of active connections followed by the list of available connections. In the list of available connections I have few VPNs configured. So, I scroll to the VPN I wish to connect to, and hit connect button. But just a fraction of second before I actually click the button, the wifi scan completes and the list of available connections updates. Now there is some wierd wifi network under the mouse and I'm connecting to who knows where...

This is a usability issue. When the list updates and the position of the item with the connect button changes, the connect buttons should be inactive for small amount of time (0.5s or so).
Comment 1 Jan Grulich 2018-09-05 15:30:29 UTC
*** Bug 398291 has been marked as a duplicate of this bug. ***
Comment 2 Jan Grulich 2018-12-06 08:26:24 UTC
*** Bug 401816 has been marked as a duplicate of this bug. ***
Comment 3 Justin Zobel 2020-11-01 04:17:22 UTC
Marking as confirmed as several other reports have been marked as duplicate against this one.
Comment 4 Dan Snis 2020-11-02 09:49:17 UTC
*** Bug 427512 has been marked as a duplicate of this bug. ***
Comment 5 Dan Snis 2020-11-02 09:59:48 UTC
If you're connected to network 'A' and want to connect to a VPN. You click the nm-applet hover over the 'connect' button for the VPN.
Then IF you have more SSID networks "remembered" they will place themself between network 'A' and the VPN in the list, making the VPN move down the list.
This update happens when you have started to click 'connect' for the VPN, but resulting in clicking 'connect' for network 'B'.
Comment 6 Dan Snis 2020-11-02 10:07:42 UTC
Created attachment 132960 [details]
nm-applet before and after update

KDE Plasma version 5.20.2
KDE Frameworks ver 5.75.0
QT Version 5.15.1

See attachment for present behaviour.

Expected behaviour:
Don't rearrange the top items in the list.
Comment 7 Nate Graham 2020-11-19 21:26:34 UTC
*** Bug 419288 has been marked as a duplicate of this bug. ***
Comment 8 Nate Graham 2020-11-19 21:27:09 UTC
*** Bug 427798 has been marked as a duplicate of this bug. ***
Comment 9 Nate Graham 2020-11-19 21:28:00 UTC
Bumping to VHI as number of dupes increases and it affects more things (now the password field is affected too).
Comment 10 Nate Graham 2020-11-19 21:32:54 UTC
*** Bug 429363 has been marked as a duplicate of this bug. ***
Comment 11 Justin Zobel 2020-11-19 21:56:31 UTC
*** Bug 428304 has been marked as a duplicate of this bug. ***
Comment 12 Justin Zobel 2020-11-19 22:14:00 UTC
*** Bug 424951 has been marked as a duplicate of this bug. ***
Comment 13 Boris 2020-12-24 16:23:39 UTC
I have the same issue (without VPN, just Wi-Fi) on Kubuntu 20.10.

Is there a way (apart from voting) to change the priority of this issue? I'm really surprised this has been hanging here for almost 3 years.
This makes Kubuntu totally unusable for my girlfriend and I'd guess for everyone else who relies on WiFi.  It also really limits the options to find a good looking distro for newbies when KDE is not an option.

(Troubleshooting and finding a workaround is not an option when trying to convince someone to switch from Windows to Linux. Internet has to work on first boot.)
Comment 14 Nate Graham 2020-12-24 16:44:15 UTC
I agree that it's an annoying issue that needs to be fixed, but "makes Kubuntu totally unusable" strikes me as a slight exaggeration given that the workaround is to simply wait a few seconds first. :)
Comment 15 Boris 2020-12-24 16:59:28 UTC
Created attachment 134313 [details]
attachment-30706-0.html

Waiting didn't work for me, they kept jumping around. So yes, no internet
means unusable in my case.

Sent from my mobile

On Thu, 24 Dec 2020, 17:44 Nate Graham, <bugzilla_noreply@kde.org> wrote:

> https://bugs.kde.org/show_bug.cgi?id=389052
>
> --- Comment #14 from Nate Graham <nate@kde.org> ---
> I agree that it's an annoying issue that needs to be fixed, but "makes
> Kubuntu
> totally unusable" strikes me as a slight exaggeration given that the
> workaround
> is to simply wait a few seconds first. :)
>
> --
> You are receiving this mail because:
> You voted for the bug.
> You are on the CC list for the bug.
Comment 16 Boris 2020-12-24 22:44:48 UTC
(In reply to Boris from comment #15)
> Created attachment 134313 [details]
> attachment-30706-0.html
> 
> Waiting didn't work for me, they kept jumping around. So yes, no internet
> means unusable in my case.
> 
> Sent from my mobile
> 
> On Thu, 24 Dec 2020, 17:44 Nate Graham, <bugzilla_noreply@kde.org> wrote:
> 
> > https://bugs.kde.org/show_bug.cgi?id=389052
> >
> > --- Comment #14 from Nate Graham <nate@kde.org> ---
> > I agree that it's an annoying issue that needs to be fixed, but "makes
> > Kubuntu
> > totally unusable" strikes me as a slight exaggeration given that the
> > workaround
> > is to simply wait a few seconds first. :)
> >
> > --
> > You are receiving this mail because:
> > You voted for the bug.
> > You are on the CC list for the bug.

I don't know if this helps, but this issue does not occur when I switch to kde on my opensuse desktop where the network was already configured before installing kde. (It does happen when I boot from the kubuntu live usb on the same system.)
Comment 17 Axel Braun 2020-12-25 08:43:35 UTC
(In reply to Boris from comment #16)

> I don't know if this helps, but this issue does not occur when I switch to
> kde on my opensuse desktop where the network was already configured before
> installing kde. (It does happen when I boot from the kubuntu live usb on the
> same system.)

If you do not connect from the drop-down list, but go via the network management menu -> Create connection -> Wifi you can chose the SSID and enter the password.
Not as comfortable as from the list, but a workaround
Comment 18 Jan Grulich 2021-01-05 11:47:40 UTC
Should be fixed or at least improved with https://invent.kde.org/plasma/plasma-nm/-/merge_requests/41.
Comment 19 Nate Graham 2021-01-05 18:45:17 UTC
Improved but not fixed, methinks.
Comment 20 Bug Janitor Service 2021-02-02 18:01:22 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-nm/-/merge_requests/47
Comment 21 Bug Janitor Service 2021-02-02 19:48:50 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-nm/-/merge_requests/48
Comment 22 Nate Graham 2022-01-11 23:16:37 UTC
*** Bug 447397 has been marked as a duplicate of this bug. ***
Comment 23 Nate Graham 2022-01-11 23:17:29 UTC
Marking as Grave since this can and does cause you to send your password to the wrong network, where it could be sniffed and compromised.
Comment 24 Nate Graham 2022-02-07 04:47:05 UTC
*** Bug 449666 has been marked as a duplicate of this bug. ***
Comment 25 Nate Graham 2022-02-07 17:31:49 UTC
*** Bug 449666 has been marked as a duplicate of this bug. ***
Comment 26 setpill 2022-02-10 00:14:15 UTC
Crossposting this for visibility;

There are two different bugs being discussed here.

1. The order of the items in the applet list changes based on signal strength, regardless of mouseover. This is this bug. The proper solution to this is to detect when an entry has mouseover, and make sure it is not reordered in that case.

2. The password entry field is associated with the nth item in the list rather than associated with the SSID. I reported this as bug 449666 which was (imho erroneously) marked as duplicate. The proper solution to this bug is to fix that association.

Most notably, in practice this is different because **it's fine for an item to change order when it has keyboard focus**. Keyboard focus can be retained even when an item changes order.
Comment 27 Cajus Pollmeier 2022-05-02 05:49:00 UTC
If you're in a place with dozens of SSIDs around, it is not possible to connect to the correct one using the applet, as the list is re-arranged all the time, and you've no chance to enter the password at that speed. As stated by others before, this can quickly become a security issue, as the password field keeps open, but suddenly belongs to the wrong entry - of whatever type.
Comment 28 Nate Graham 2022-05-10 15:47:59 UTC
*** Bug 453598 has been marked as a duplicate of this bug. ***
Comment 29 Nate Graham 2022-07-15 18:49:05 UTC
*** Bug 435430 has been marked as a duplicate of this bug. ***
Comment 30 Nate Graham 2022-07-15 18:49:11 UTC
*** Bug 442749 has been marked as a duplicate of this bug. ***
Comment 31 Axel Braun 2022-07-22 14:15:18 UTC
Wow...shall we light a candle for the (coming) 4th anniversary of this annoying bug?
Comment 32 Marcin Juszkiewicz 2022-07-22 19:28:08 UTC
(In reply to Axel Braun from comment #31)
> Wow...shall we light a candle for the (coming) 4th anniversary of this
> annoying bug?

This reminds me why I stopped filing bugs against KDE.
Comment 33 Nate Graham 2022-09-26 18:56:37 UTC
*** Bug 459604 has been marked as a duplicate of this bug. ***
Comment 34 Bug Janitor Service 2022-09-29 01:35:17 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-nm/-/merge_requests/153
Comment 35 Bug Janitor Service 2022-09-29 01:35:21 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-nm/-/merge_requests/153
Comment 36 ratijas 2022-10-04 11:37:19 UTC
Git commit 9e5cdc3e4f0b83221310560f2e4966c7d5fa59bc by ivan tkachenko.
Committed on 04/10/2022 at 10:06.
Pushed by ratijas into branch 'master'.

applet: Fix delayModelUpdates mode

The delayModelUpdates write-only property was a workaround, but it
didn't even work properly especially with multiple delegates
(writers) per single shared variable. This patch promotes the concept
into a model role, and turns the model's shared property into readonly
aggregated state. This should fix most of the cases when a connection
would suddenly teleport away or even replaced with another while typing
in password.

M  +7    -9    applet/contents/ui/ConnectionItem.qml
M  +4    -1    applet/contents/ui/main.qml
M  +57   -17   libs/models/networkmodel.cpp
M  +14   -4    libs/models/networkmodel.h
M  +13   -0    libs/models/networkmodelitem.cpp
M  +4    -0    libs/models/networkmodelitem.h

https://invent.kde.org/plasma/plasma-nm/commit/9e5cdc3e4f0b83221310560f2e4966c7d5fa59bc
Comment 37 ratijas 2022-10-04 11:37:27 UTC
Git commit 6a6cbe10c9eaabf6bcd8ae2b12df7f0ea6903cc1 by ivan tkachenko.
Committed on 04/10/2022 at 10:06.
Pushed by ratijas into branch 'master'.

applet: Block all role changes while in delayModelUpdates mode

Practically all roles are accounted for when comparing connections in
downstream sort-filter proxy model. Let's block all roles from
propagating changes while scan delay is requested to avoid surprises.

Partially helps, but not fully fixes:

M  +1    -3    libs/models/networkmodel.cpp

https://invent.kde.org/plasma/plasma-nm/commit/6a6cbe10c9eaabf6bcd8ae2b12df7f0ea6903cc1
Comment 38 ratijas 2022-10-04 12:05:38 UTC
Git commit d83674e5ed171e590223a2fc0b6d49da09e245dc by ivan tkachenko.
Committed on 04/10/2022 at 12:05.
Pushed by ratijas into branch 'Plasma/5.26'.

applet: Block all role changes while in delayModelUpdates mode

Practically all roles are accounted for when comparing connections in
downstream sort-filter proxy model. Let's block all roles from
propagating changes while scan delay is requested to avoid surprises.

Partially helps, but not fully fixes:
(cherry picked from commit 6a6cbe10c9eaabf6bcd8ae2b12df7f0ea6903cc1)

M  +1    -3    libs/models/networkmodel.cpp

https://invent.kde.org/plasma/plasma-nm/commit/d83674e5ed171e590223a2fc0b6d49da09e245dc
Comment 39 ratijas 2022-10-04 12:05:46 UTC
Git commit 575e9e912b93b10b7fd337a5c100ac533b6ca4e2 by ivan tkachenko.
Committed on 04/10/2022 at 12:05.
Pushed by ratijas into branch 'Plasma/5.26'.

applet: Fix delayModelUpdates mode

The delayModelUpdates write-only property was a workaround, but it
didn't even work properly especially with multiple delegates
(writers) per single shared variable. This patch promotes the concept
into a model role, and turns the model's shared property into readonly
aggregated state. This should fix most of the cases when a connection
would suddenly teleport away or even replaced with another while typing
in password.
(cherry picked from commit 9e5cdc3e4f0b83221310560f2e4966c7d5fa59bc)

M  +7    -9    applet/contents/ui/ConnectionItem.qml
M  +4    -1    applet/contents/ui/main.qml
M  +57   -17   libs/models/networkmodel.cpp
M  +14   -4    libs/models/networkmodel.h
M  +13   -0    libs/models/networkmodelitem.cpp
M  +4    -0    libs/models/networkmodelitem.h

https://invent.kde.org/plasma/plasma-nm/commit/575e9e912b93b10b7fd337a5c100ac533b6ca4e2
Comment 40 ratijas 2022-10-04 12:06:44 UTC
> > Wow...shall we light a candle for the (coming) 4th anniversary of this
> > annoying bug?
> 
> This reminds me why I stopped filing bugs against KDE.

And that reminds me why I started fixing them 😬