1
0
mirror of https://github.com/gryf/wicd.git synced 2025-12-25 07:32:29 +01:00
Commit Graph

480 Commits

Author SHA1 Message Date
24117dbf81 Fix bytes/string issue for subprocess 2020-08-25 20:05:40 +02:00
d4fc621f4f Fixed property name for the wired interface 2020-08-01 19:24:01 +02:00
40a7a8ac5d Style changes for python files 2020-08-01 11:37:26 +02:00
48bac465d4 Fixed files permission 2020-07-30 16:34:10 +02:00
Axel Beckert
f090e292dc Fix wicd-curses warnings in status bar and similar cases
Replace all occurrences of "from gi.repository import GObject as
gobject" with "from gi.repository import GLib as gobject".
2019-09-12 00:59:05 +02:00
Guido Serra
5860ad8251 updated shebangs & other p3 references 2019-09-11 12:14:15 +02:00
Axel Beckert
c1c26d8112 Remaining needed changes to get the daemon running with Python 3 2019-09-11 02:43:20 +02:00
Axel Beckert
c238d26a9e Fix "NameError: name 'cmp' is not defined"
Source: https://codegolf.stackexchange.com/questions/49778/how-can-i-use-cmpa-b-with-python3

Now the wicd daemon starts as "/usr/sbin/wicd -c -f -e -o" wihout
errors, only warnings are left.

wicd-curses also runs but spews warnings into the status line, too.
2019-09-11 01:40:43 +02:00
Axel Beckert
9587c52c88 Fix "TypeError: cmp is an invalid keyword argument for sort()" 2019-09-11 01:33:03 +02:00
Axel Beckert
c2789eb467 Fix "TypeError: sorted expected 1 arguments, got 2" 2019-09-11 01:29:07 +02:00
Axel Beckert
fef2a43a59 Fix LogFile class by using io.FileIO instead of file
Thanks to Frank Hofmann for the right pointer to
https://stackoverflow.com/questions/47838405/porting-a-sub-class-of-python2-file-class-to-python3

Now at least "/usr/sbin/wicd -c -f -e -o" keeps running.

Still throws errors and warnings, though:

/usr/share/wicd/daemon/wicd-daemon.py:1925: PyGIDeprecationWarning: GObject.MainLoop is deprecated; use GLib.MainLoop instead
  mainloop = gobject.MainLoop()
/usr/share/wicd/daemon/monitor.py:392: PyGIDeprecationWarning: GObject.MainLoop is deprecated; use GLib.MainLoop instead
  mainloop = gobject.MainLoop()
Exception in thread Thread-1:
Traceback (most recent call last):
  File "/usr/lib/python3.7/threading.py", line 926, in _bootstrap_inner
    self.run()
  File "/usr/lib/python3.7/threading.py", line 870, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/share/wicd/daemon/wicd-daemon.py", line 1020, in _async_scan
    self._sync_scan()
  File "/usr/share/wicd/daemon/wicd-daemon.py", line 1024, in _sync_scan
    scan = self.wifi.Scan(str(self.hidden_essid))
  File "/usr/lib/python3/dist-packages/wicd/networking.py", line 673, in Scan
    aps = wiface.GetNetworks(essid)
  File "/usr/lib/python3/dist-packages/wicd/wnettools.py", line 227, in newfunc
    return func(self, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/wicd/wnettools.py", line 1392, in GetNetworks
    entry = self._ParseAccessPoint(cell, ralink_info)
  File "/usr/lib/python3/dist-packages/wicd/wnettools.py", line 1447, in _ParseAccessPoint
    ap['bitrates'] = sorted(m, lambda x, y: int(float(x) - float(y)))
TypeError: sorted expected 1 arguments, got 2
2019-09-11 01:24:27 +02:00
Axel Beckert
187f85f6a0 More Python 3 fixes needed to also install the packages
Daemon still does not start. It fails as follows:

Traceback (most recent call last):
  File "/usr/share/wicd/daemon/wicd-daemon.py", line 62, in <module>
    from wicd.logfile import ManagedStdio
  File "/usr/lib/python3/dist-packages/wicd/logfile.py", line 32, in <module>
    class LogFile(file):
NameError: name 'file' is not defined
2019-09-11 01:16:58 +02:00
Guido Serra
15ca072eed another step fwd 2019-09-10 09:50:56 +02:00
Guido Serra
404545ffd5 I am a ... nevermind 2019-09-09 11:59:20 +02:00
Guido Serra
fbc67695a5 a proper signature, else we get the error Alex reported 2019-09-09 11:47:36 +02:00
Guido Serra
94bf1ab01e seems we made it properly maketrans() 2019-08-30 14:50:21 +02:00
Guido Serra
b92d5b052e unicode encoded is bytes 2019-08-29 14:35:47 +02:00
Guido Serra
6888489192 unnecessary... maybe cause of python3 2019-08-14 18:07:56 +02:00
Guido Serra
ffaa780c07 we were getting a bytes obj 2019-08-14 18:01:13 +02:00
Guido Serra
364db09a6e we are at failing tests, good 2019-08-14 16:24:14 +02:00
Guido Serra
2a52b83583 attempting to migrate to python 3.x 2019-08-14 16:18:46 +02:00
Guido Maria Serra
681beb13b1 2to3 transformation 2019-08-12 17:00:19 +02:00
Tom Van Braeckel
0d4c16f0ca wicd: Fix the parsing and writing of wep-hex configurations (launchpad bug #1419464)
Thanks, Axel Beckert from Debian!

***

 Symptom: Can't connect to WEP based networks with hexadecimal keys
 due to unexpanded template variables like $_KEY in the actual
 wpa_supplicant configurations.

 Solution: Move the appending of the line outside the loop over all
 matches in one line.

Author: Axel Beckert <abe@debian.org>
Bug-Debian: https://bugs.debian.org/812427
Bug: https://bugs.launchpad.net/wicd/+bug/1419464
2016-01-25 04:47:18 +01:00
Tom Van Braeckel
be575c21df Add possibility to pass extra arguments to the DHCP client commands, and use this option when a global DNS server has been set, to avoid resolv.conf being overwritten by the DHCP client when receiving a DHCP reply that contains a DNS server.
This should fix https://bugs.launchpad.net/wicd/+bug/145405.
Credits for the original patch go to "Leonardo" :-)

Plus, translations...
2015-02-14 11:44:03 +01:00
Tom Van Braeckel
29c12dc0d2 Wireless network interface should only be auto-detected when nothing is specified in /etc/wicd/manager-settings.conf
If the user makes this empty, it will not be autodetected anymore.
2015-02-12 18:01:42 +01:00
Tom Van Braeckel
513a1a2215 Improve handling of None values in the configuration file
When wireless_interface is not filled in, it should be autodetected.
But because this is set to None, the autodetection fails...
2015-02-12 15:45:24 +01:00
Tom Van Braeckel
8feb310a32 Fix scanning of hidden networks 2015-02-12 13:44:32 +01:00
Tom Van Braeckel
4f8ef8a6a8 Improve debugging output 2015-02-12 12:43:18 +01:00
Tom Van Braeckel
754d8e0fa3 Merge "Javier P.L. 2013-12-06 allow wicd daemon to start even if /etc/resolv.conf is a relative symlink"
https://code.launchpad.net/~chilicuil/wicd/wicd/+merge/198057

Bugreports:
https://bugs.launchpad.net/wicd/+bug/1193856
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=691973
https://bugs.launchpad.net/wicd/+bug/1171296
2014-12-11 14:50:12 +01:00
Tom Van Braeckel
d32482afb9 Automatic reconnect: honour the automatic reconnect configuration, even if the GUI interface is open
When a user actives "automatic reconnnect" and then tries this out, he will be staring at the GUI interface, waiting for a reconnect.
But wicd-daemon refuses to reconnect when the GUI interface is open, and fails to reports this to the GUI user.
Hence users assume that this feature does not work properly (see https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=582567).

This commit fixes that by doing a reconnect, no matter whether the GUI is open or not, thus taking the path of "least surprise".
The original rationale for not reconnecting when the GUI is open was never stated in the comments, nor in the commit message.
2014-11-05 07:32:28 +01:00
Javier P.L.
cf1abd68dc allow wicd daemon to start even if /etc/resolv.conf is a relative symlink 2013-12-06 07:42:39 -06:00
David Paleino
6c7124c80a Don't try to set wireless bitrate to "autoM" 2013-02-15 22:30:48 +01:00
David Paleino
d6170583a7 Change behaviour when dealing with hostnames: don't send any if the user didn't tick the box (previously, the current system name was sent). 2013-02-01 22:14:15 +01:00
David Paleino
2eded80a9b Make sure we don't die if the kernel doesn't support some socket family 2013-01-23 21:20:27 +01:00
David Paleino
259836c295 Specify DBus signature (useful when list is empty) 2012-11-22 09:02:04 +01:00
David Paleino
1f0b5674cf Change defaul behaviour: now wicd kills connections when is shutdown. This behaviour can be overriden with -c/--keep-connection (to the daemon). 2012-11-21 18:35:35 +01:00
David Paleino
42aac8ce10 Improve checking of input values 2012-11-18 00:15:22 +01:00
David Paleino
54ef2e642b Fix bug in configmanager, due to pylint-related edits 2012-11-18 00:15:04 +01:00
David Paleino
b5a4d70ab8 Fix some issues by pylint 2012-11-17 01:07:08 +01:00
David Paleino
5508781f1f Fix bug within GetWirelessInterfaces() 2012-11-16 21:02:06 +01:00
David Paleino
6a3f90853f Reliably detect the wireless interface. Thank to Markus Fuchs for investigations and patch. (LP: #415719) 2012-11-15 09:48:54 +01:00
David Paleino
4b9a79a462 Correctly flush resolvconf DNS records 2012-11-01 17:22:59 +01:00
David Paleino
20e02cd191 Fix error when trying to overwrite existing /etc/resolv.conf with the backup 2012-11-01 00:27:50 +01:00
David Paleino
ad8fab20d2 Correctly handle the case where resolv.conf is a symlink (Debian: #691973) 2012-10-31 23:35:10 +01:00
David Paleino
3baf6df9c9 Correctly loop over all variables found in each line (LP: #897399) 2012-10-31 22:27:32 +01:00
David Paleino
056fd3b833 Fix call to resolvconf when adding a DNS record (Debian: #691974) 2012-10-31 21:50:05 +01:00
Michael Terry
d18c82187f make sure that SetConnectionStatus is called with an array of only strings 2012-10-11 15:42:59 -04:00
David Paleino
7cb482a9fc Implement iwconfig bitrate setting 2012-09-27 22:18:04 +02:00
David Paleino
93a30244e3 Implement --status/-i in wicd-cli, to show current connection status. 2012-09-26 17:32:12 +02:00
David Paleino
1ece88dd29 Generalize essid recognition regex 2012-09-24 17:17:53 +02:00