Hi, I'm Daniel, but not the original reporter :)

Anyway. I took a Dell Inspiron 1545 and connected to a wireless network
named Ubuntu. I then renamed the "Wired Connection 1" default ethernet
to "Ubuntu". nmcli con list shows two Ubuntu networks. The first one
that appears on the list is the Ethernet one.

As per the reproduction case I unplug the Ethernet cable. I'm able to
ping some hosts on the wireless network as I'm still connected on that
one.

I then run /usr/share/checkbox/scripts/connect_wireless from Checkbox
0.12.8 and I get:

Error: Device 'eth0' (/org/freedesktop/NetworkManager/Devices/1) disconnecting 
failed: This device is not active
Device state: 30 (disconnected)
Error: Unknown connection: 343b92b1-1049-406c-bfd9-a636b93cacdf 
8ddcecca-5513-495f-9525-b611bf620868.

The wireless connection remains disconnected and I can't ping anything.

I then installed Checkbox 0.12.9 from -proposed. I brought up the
wireless connection. I then ran the same script and got the same result
:( (notice the slight difference in the last line, here it can't even
find a connection name)

Error: device 'eth0 (/org/freedesktop/NetworkManager/Devices/1) disconnecting 
failed: this device is not active
Device state: 30 (disconnected)
Error: Unknown connection: .

I went looking into the code and the problem is that, even though it's
now filtering only the wireless connections (line 11 of
connect_wireless), it had to add the TYPE field to nmcli output to be
able to do so. However, later in the same line, it looks for the network
name at the *end* of the line (grep -e '$ap$' where $ap contains the
network name). Since the TYPE field was added at the end of the line,
the script fails in a slightly different way.

The fix for the fix is to swap TYPE and NAME in line 11 so the field
list looks like UUID,TYPE,NAME.

As the SRUed fix is not working as intended, I'll mark verification-
failed. Also, the faulty code is also present in checkbox trunk, it will
have to be fixed there as well.

Please let me know how to proceed with this bug report.

Thanks!

** Tags removed: verification-needed
** Tags added: verification-failed

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/877752

Title:
  connect_wireless can unintentionally choose a non-wireless connection
  to connect to

To manage notifications about this bug go to:
https://bugs.launchpad.net/checkbox/+bug/877752/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to