[pkg-wicd-maint] Bug#833929: wicd-daemon: takes time to reconnect / autoconnect after connection loss

Vincent Lefevre vincent at vinc17.net
Sun Jul 14 23:59:49 BST 2019


On 2018-12-04 20:12:59 +0700, Giap Tran wrote:
> Hi Vincent Lefevre,
> 
> The first, I'm sorry for handling late.
> Thank you for your patch. I applied the patch
> 
> https://salsa.debian.org/debian/wicd/merge_requests/1

Actually the patch may be wrong (though currently, wicd would
be better with it than without it); I think that it is just a
workaround to a more general bug:

  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=932042

(there, for a network without "Automatically connect to this network"
set, this patch does not improve anything).

The reason is given here:

    def GetGUIOpen(self):
        """ Returns the value of gui_open.

        Returns the vlaue of gui_open, which is a boolean that keeps track
        of the state of the wicd GUI.  If the GUI is open, wicd will not
        try to automatically reconnect to networks, as this behavior can
        be annoying for the user while trying to use the GUI.

        NOTE: It's possible for this to become out of sync, particularly if
        the wicd.py is not exited properly while the GUI is open.  We should
        probably implement some kind of pid system to do it properly.

        ANOTHER NOTE: This isn't used by anything yet!

        """
        return bool(self.gui_open)

but I disagree. I think that one needs to make a difference between
reconnecting to some network because the connection was lost due to
some external cause and connecting to some network that has the
option "Automatically connect to this network".

In the former case, one wants wicd to reconnect even when the GUI is
open. The latter case occurs when the user chose to disconnect, e.g.
via the GUI (but not necessarily). Obviously, if the user chose to
disconnect from the GUI, one does not want wicd to reconnect to this
network (or another one). But IMHO, if the user closes the GUI after
disconnecting, wicd shouldn't try to connect automatically either.

The autoconnection logic should be rethought. IMHO, it should occur
in 2 cases (if I'm not missing anything):
  * on startup;
  * when the network was not present in the previous scan (there may
    be corner cases, where the user disconnected from this network,
    then this network was no longer present, and later this network
    reappears... it is not clear what to do, but well, in this case,
    the user could disconnect again anyway).

Note: This does not cover the reconnection after a connection loss,
which should have a separate logic.

-- 
Vincent Lefèvre <vincent at vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)



More information about the pkg-wicd-maint mailing list