#626 closed defect (invalid)
SoaS: spurious storage devices in Frame on bootup
Reported by: | tomeu | Owned by: | tomeu |
---|---|---|---|
Priority: | Immediate | Milestone: | |
Component: | Sugar | Version: | Git as of bugdate |
Severity: | Critical | Keywords: | |
Cc: | sascha_silbe, m_anish | Distribution/OS: | Fedora |
Bug Status: | Assigned |
Description
On Soas-2, when you boot, two devices appear in the frame: /media/boot and /media/F10-PR-i686-Live
None of those bring value to the user, so shouldn't appear there.
Change History (23)
comment:1 Changed 14 years ago by FGrose
- Bug Status changed from Unconfirmed to New
- Summary changed from spurious storage devices on bootup to spurious storage devices in Frame on bootup
comment:2 Changed 14 years ago by tomeu
- Severity changed from Unspecified to Blocker
comment:3 Changed 14 years ago by tomeu
comment:4 follow-up: ↓ 6 Changed 14 years ago by sascha_silbe
- Cc sascha_silbe added
What about USB harddisks? Is it fine that they won't be automounted (which would probably happen after applying the patch, as they're not removable media)?
comment:5 Changed 14 years ago by tomeu
A better patch, because in some systems mounts won't have a drive associated:
diff --git a/extensions/deviceicon/volume.py b/extensions/deviceicon/volume.py index 96d0796..4b12eab 100644 --- a/extensions/deviceicon/volume.py +++ b/extensions/deviceicon/volume.py @@ -33,6 +33,7 @@ from sugar.graphics import style from jarabe.journal import journalactivity from jarabe.view.palettes import VolumePalette from jarabe.frame.frameinvoker import FrameWidgetInvoker +from jarabe import util _icons = {} @@ -115,6 +116,10 @@ def _mount_removed_cb(volume_monitor, mount, tray): del _icons[mount] def _add_device(mount, tray): + + if util.should_ignore_mount(mount): + return + icon = DeviceView(mount) _icons[mount] = icon tray.add_device(icon) diff --git a/src/jarabe/journal/volumestoolbar.py b/src/jarabe/journal/volumestoolbar.py index b21832e..651962f 100644 --- a/src/jarabe/journal/volumestoolbar.py +++ b/src/jarabe/journal/volumestoolbar.py @@ -28,6 +28,7 @@ from sugar.graphics.xocolor import XoColor from jarabe.journal import model from jarabe.view.palettes import VolumePalette +from jarabe import util class VolumesToolbar(gtk.Toolbar): __gtype_name__ = 'VolumesToolbar' @@ -78,6 +79,9 @@ class VolumesToolbar(gtk.Toolbar): def _add_button(self, mount): logging.debug('VolumeToolbar._add_button: %r' % mount.get_name()) + if util.should_ignore_mount(mount): + return + button = VolumeButton(mount) button.props.group = self._volume_buttons[0] button.connect('toggled', self._button_toggled_cb) @@ -165,8 +169,6 @@ class VolumeButton(BaseButton): def create_palette(self): palette = VolumePalette(self._mount) - #palette.props.invoker = FrameWidgetInvoker(self) - #palette.set_group_id('frame') return palette class JournalButton(BaseButton): diff --git a/src/jarabe/util/__init__.py b/src/jarabe/util/__init__.py index 1610dd0..267208a 100644 --- a/src/jarabe/util/__init__.py +++ b/src/jarabe/util/__init__.py @@ -17,3 +17,10 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +def should_ignore_mount(mount): + drive = mount.get_drive() + if drive is not None and not drive.is_media_removable(): + # Mounts in drives that aren't removable aren't interesting + return True + + return False
comment:6 in reply to: ↑ 4 Changed 14 years ago by tomeu
Replying to sascha_silbe:
What about USB harddisks? Is it fine that they won't be automounted (which would probably happen after applying the patch, as they're not removable media)?
Sascha is right, just plugged in a usb hard disk and it wasn't recognized in the same way as usb sticks are.
comment:7 Changed 14 years ago by tomeu
Have checked the way Nautilus displays removable devices and is quite similar to ours, probably displaying the same problem on fedora live images. We should check if that's the case and work with upstream in a common solution.
comment:8 Changed 14 years ago by tomeu
Entered bugs for nautilus, I hope the solution that is found for nautilus is also valid for Sugar:
https://bugzilla.redhat.com/show_bug.cgi?id=495029
https://bugzilla.redhat.com/show_bug.cgi?id=495033
comment:9 Changed 14 years ago by tomeu
Good progress happened yesterday, will update soas after the weekend and check where we are at.
comment:10 Changed 14 years ago by sdz
- Bug Status changed from New to Resolved
- Resolution set to fixed
- Status changed from new to closed
Confirmed to be fixed with latest gvfs and DeviceKit-disks from Rawhide.
comment:11 Changed 14 years ago by tomeu
- Resolution fixed deleted
- Status changed from closed to reopened
This one seems to have come to life again, reopened:
comment:12 Changed 14 years ago by erikos
- Bug Status changed from Resolved to Assigned
sdz, we have to be watch out for this one as well - as it was not on our list yesterday.
comment:13 Changed 14 years ago by alsroot
- Milestone changed from 0.84 to 0.86
- Priority changed from Unspecified by Maintainer to Immediate
comment:14 Changed 14 years ago by erikos
- Severity changed from Blocker to Critical
comment:15 Changed 13 years ago by sascha_silbe
- Component changed from sugar to SoaS
- Distribution/OS changed from SoaS to Unspecified
Bulk change distribution=SoaS -> component=SoaS
comment:16 Changed 13 years ago by sdz
- Component changed from SoaS to sugar
This is a sugar issue that got accidentally assigned to SoaS during an auto-tag. Reassigning - sorry for the confusion.
comment:17 Changed 13 years ago by bernie
Is this still a problem in 0.88 or 0.90? If so, we should change milestone
comment:18 Changed 13 years ago by sascha_silbe
At least with Sugar 0.89 on Debian Squeeze I get Frame device icons for partitions and LVs mounted at boot time.
On one of my systems it even tries to mount / a second time:
1282377612.372566 DEBUG root: _mount_cb <__main__.GProxyVolume at 0xa43c57c: xo15-sascha-root> <gio.SimpleAsyncResult object at 0xa91293c (GSimpleAsyncResult at 0xa94f700)> Traceback (most recent call last): File "/usr/share/sugar/extensions/deviceicon/volume.py", line 107, in _mount_cb volume.mount_finish(result) glib.GError: Error mounting: mount exited with exit code 1: helper failed with: mount: according to mtab, /dev/mmcblk0p1 is already mounted on / mount failed
I can open a new ticket for the latter issue if you think it's unrelated.
Why is this set to Critical, BTW? I don't see any potential for data loss, crashes or similar.
comment:19 Changed 13 years ago by sascha_silbe
- Milestone changed from 0.86 to 0.90
comment:20 Changed 12 years ago by m_anish
- Cc m_anish added
comment:21 Changed 10 years ago by manuq
- Distribution/OS changed from Unspecified to Fedora
- Summary changed from spurious storage devices in Frame on bootup to SoaS: spurious storage devices in Frame on bootup
comment:22 Changed 10 years ago by dnarvaez
- Resolution set to invalid
- Status changed from reopened to closed
3 years old bug, we don't have resources to retriage. If you still see it in latest soas please open a new bug.
This seems to work here: