After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 646074 - NetworkManager 0.9 indicator doesn't show device name
NetworkManager 0.9 indicator doesn't show device name
Status: RESOLVED FIXED
Product: gnome-shell
Classification: Core
Component: network-indicator
2.91.x
Other Linux
: Normal normal
: ---
Assigned To: gnome-shell-maint
gnome-shell-maint
: 646128 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2011-03-29 11:04 UTC by Luis Medinas
Modified: 2011-04-11 14:46 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
NetworkMenu: fixup device descriptions (1.40 KB, patch)
2011-03-29 12:30 UTC, Giovanni Campagna
committed Details | Review
NetworkMenu: fix some bugs for status items (1.95 KB, patch)
2011-03-31 21:25 UTC, Giovanni Campagna
reviewed Details | Review
NetworkMenu: fix some bugs for status items (3.16 KB, patch)
2011-04-06 16:47 UTC, Giovanni Campagna
none Details | Review
NetworkMenu: fix some bugs for status items (3.23 KB, patch)
2011-04-06 16:48 UTC, Giovanni Campagna
committed Details | Review

Description Luis Medinas 2011-03-29 11:04:41 UTC
In the current NM 0.9 indicator doesn't show device names. This is pretty bad for me that i have a broken wifi card and i have to figure out which one is the good one.
This is a regression from 0.8 applet.
Comment 1 Giovanni Campagna 2011-03-29 12:30:50 UTC
Created attachment 184574 [details] [review]
NetworkMenu: fixup device descriptions

Fix some bugs in Util.fixupPCIDescription(), that caused all device
descriptions to be empty.
Comment 2 Dan Winship 2011-03-29 13:19:00 UTC
Comment on attachment 184574 [details] [review]
NetworkMenu: fixup device descriptions

>-        'Intel?',
>+        'Intel',

nm-applet has the "?". (I remember checking before because it seemed weird.) I guess it was a bug there and it's been fixed now?

The rest looks right.

(Marking commit-after-freeze; talk to Owen if you want to commit-now.)
Comment 3 Dan Winship 2011-03-29 13:19:17 UTC
actually, this will presumably change UI as well?
Comment 4 Giovanni Campagna 2011-03-29 13:27:32 UTC
(In reply to comment #2)
> (From update of attachment 184574 [details] [review])
> >-        'Intel?',
> >+        'Intel',
> 
> nm-applet has the "?". (I remember checking before because it seemed weird.) I
> guess it was a bug there and it's been fixed now?

No, it's still there in network-manager-applet. Don't know for sure if it is a bug, but I don't think we want to strip "Intel?" but not "Intel".

Anyway, I'm fine with postponing this to 3.0.1, or to 3.1.1 if UI freeze applies.
Comment 5 Luis Medinas 2011-03-29 13:28:31 UTC
If it's like the 0.8 applet it should change the UI a bit so it can display the device name. Please consider this for 3.0 since it will affect users with more than one device.
Comment 6 Giovanni Campagna 2011-03-29 13:30:01 UTC
(In reply to comment #5)
> If it's like the 0.8 applet it should change the UI a bit so it can display the
> device name. Please consider this for 3.0 since it will affect users with more
> than one device.

Uhm... aren't you seeing like two empty spaces, above each network device?
Comment 7 Luis Medinas 2011-03-29 13:36:00 UTC
(In reply to comment #6)
> (In reply to comment #5)
> > If it's like the 0.8 applet it should change the UI a bit so it can display the
> > device name. Please consider this for 3.0 since it will affect users with more
> > than one device.
> 
> Uhm... aren't you seeing like two empty spaces, above each network device?

Yep!!
Comment 8 Giovanni Campagna 2011-03-29 13:37:02 UTC
Are both devices managed by NM?
Do you see any error on stdout?
Comment 9 Luis Medinas 2011-03-29 13:47:18 UTC
(In reply to comment #8)
> Are both devices managed by NM?
Yes, two wifi devices: one usb and another internal pci. NM runs the two without any problems but the indicator doesn't display the name of them.

> Do you see any error on stdout?
No luck on this one :/
Comment 10 Giovanni Campagna 2011-03-31 21:25:55 UTC
Created attachment 184825 [details] [review]
NetworkMenu: fix some bugs for status items

When more than one device exists, we need to reset the section title's
device to null, and in that case we must show nothing (neither the switch
nor the label, but an empty label is OK anyway). Also, we need to
update the device statusItem immediately when constructing it, as we
may not get any state-changed.
Comment 11 Giovanni Campagna 2011-04-02 17:02:00 UTC
*** Bug 646128 has been marked as a duplicate of this bug. ***
Comment 12 Dan Winship 2011-04-04 12:57:06 UTC
Comment on attachment 184825 [details] [review]
NetworkMenu: fix some bugs for status items

>+            this.statusItem.setStatus(this.getStatusLabel());
>+            this.statusItem.setToggleState(this.connected);

it seems like it would be better to run this._deviceStateChanged(), or at least, to have both cases call some common subroutine. Otherwise at some point we're going to add something to deviceStateChanged() and forget that we have to add it here as well.

>-        if (this.titleItem)
>-            this.titleItem.destroy();
>+        if (this.statusItem)
>+            this.statusItem.destroy();

obviously correct

>+                item.updateForDevice(null);

That should probably get a comment explaining what/why.


Also, this is not new with your patches, but if I connect and then disconnect a USB ethernet device, the "Wired" heading goes back to behaving like it's supposed to, and the entry for my built-in ethernet disappears, but the entry for the USB ethernet device is still there, with the status "invalid".
Comment 13 Giovanni Campagna 2011-04-06 16:42:07 UTC
(In reply to comment #12)
> (From update of attachment 184825 [details] [review])
> Also, this is not new with your patches, but if I connect and then disconnect a
> USB ethernet device, the "Wired" heading goes back to behaving like it's
> supposed to, and the entry for my built-in ethernet disappears, but the entry
> for the USB ethernet device is still there, with the status "invalid".

Do ModemManager / NetworkManager still expose the device? (You can check in d-feet)
Can you confirm that NMApplet._deviceRemoved is called?
Can you confirm that NMDevice.destroy is called, on the right device?
Comment 14 Giovanni Campagna 2011-04-06 16:47:57 UTC
Created attachment 185335 [details] [review]
NetworkMenu: fix some bugs for status items

When more than one device exists, we need to reset the section title's
device to null, and in that case we must show nothing (neither the switch
nor the label, but an empty label is OK anyway). Also, we need to
update the device statusItem immediately when constructing it, as we
may not get any state-changed.
Comment 15 Giovanni Campagna 2011-04-06 16:48:31 UTC
Created attachment 185337 [details] [review]
NetworkMenu: fix some bugs for status items

When more than one device exists, we need to reset the section title's
device to null, and in that case we must show nothing (neither the switch
nor the label, but an empty label is OK anyway). Also, we need to
update the device statusItem immediately when constructing it, as we
may not get any state-changed.

Forgot to git add one piece.
Comment 16 Dan Winship 2011-04-07 16:34:02 UTC
Comment on attachment 185337 [details] [review]
NetworkMenu: fix some bugs for status items

looks good

(on the other problem: device-removed is not being emitted. I'll poke around in NM)
Comment 17 Dan Winship 2011-04-11 14:45:59 UTC
Attachment 184574 [details] pushed as b2b685e - NetworkMenu: fixup device descriptions
Attachment 185337 [details] pushed as 2d855ce - NetworkMenu: fix some bugs for status items