OneConf synchronous networking delays USC launching

Bug #638142 reported by Matthew Paul Thomas
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
oneconf (Ubuntu)
Fix Released
Medium
Unassigned

Bug Description

Binary package hint: oneconf

oneconf 0.1.1, software-center 2.1.19, Ubuntu Maverick

1. With oneconf installed, enter the terminal command "trickle -d 1 software-center".

What should happen: Ubuntu Software Center launches.
What actually happens: Nothing.

The problem occurs only if oneconf is installed.

Pressing Ctrl C produces this traceback:
^CTraceback (most recent call last):
  File "/usr/bin/software-center", line 90, in <module>
    app = SoftwareCenterApp(datadir, xapian_base_path, options, args)
  File "/usr/share/software-center/softwarecenter/app.py", line 383, in __init__
    self.plugin_manager.load_plugins()
  File "/usr/share/software-center/softwarecenter/plugin.py", line 113, in load_plugins
    module = self._load_module(filename)
  File "/usr/share/software-center/softwarecenter/plugin.py", line 90, in _load_module
    (".py", "r", imp.PY_SOURCE))
  File "/usr/share/software-center/plugins/oneconf_plugin.py", line 35, in <module>
    from oneconf.dbusconnect import DbusConnect
  File "/usr/share/oneconf/oneconf/dbusconnect.py", line 24, in <module>
    from oneconf.hosts import Hosts, HostError
  File "/usr/share/oneconf/oneconf/hosts.py", line 23, in <module>
    from desktopcouch.records.server import CouchDatabase
  File "/usr/lib/python2.6/dist-packages/desktopcouch/__init__.py", line 20, in <module>
    from desktopcouch.start_local_couchdb import process_is_couchdb, read_pidfile
  File "/usr/lib/python2.6/dist-packages/desktopcouch/start_local_couchdb.py", line 38, in <module>
    from desktopcouch import local_files
  File "/usr/lib/python2.6/dist-packages/desktopcouch/local_files.py", line 298, in <module>
    xdg_base_dirs.save_config_path("desktop-couch"))
  File "/usr/lib/python2.6/dist-packages/desktopcouch/local_files.py", line 233, in __init__
    self.couch_exec_command = [COUCH_EXE, self.couch_chain_ini_files(),
  File "/usr/lib/python2.6/dist-packages/desktopcouch/local_files.py", line 273, in couch_chain_ini_files
    line = process.stdout.read().split('\n')[0]
KeyboardInterrupt

Related branches

Revision history for this message
Didier Roche-Tolomelli (didrocks) wrote :

right, OneConf is starting async apart from the first critical part when the main pluging load. So, when it's import DbusConnect, it's starting, it's starting beam.smp as well, which can takes time.

So, this import should just be delayed in a thread so that beam.smp intialize in non blocking mode. Tricky and not maverick, but worth investigating it.

An another solution is that desktopcouch initialize in non blocking mode and give a callback once ready…

Changed in oneconf (Ubuntu):
status: New → Triaged
importance: Undecided → Medium
Revision history for this message
Didier Roche-Tolomelli (didrocks) wrote :

I worked on launching desktopcouch only from the daemon and not from the plugin. Consequently, this issue shouldn't happen anymore, can you confirm with oneconf trunk?

You just have to branch the trunk, and then, symlink /usr/share/software-center/plugins/oneconf_plugin.py to <oneconf-trunk>/oneconf/usc_plugin.py

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package oneconf - 0.2

---------------
oneconf (0.2) oneiric; urgency=low

  * New release:
    - move from desktopcouch to a json cache file base version, build a
      server/client protocol based on ubuntu-webcatalog (server part will be
      oneline soon). (LP: #720498, #715514, #748517)
    - adapt to latest software-center in oneiric
    - harden a lot regards to bug handling timeouts and such
      (LP: #616463, #625554, #804768, #594394)
    - optimize startup time with json and don't wait on server side sync
      (LP: #638142, #780651)
    - adapt now with ubuntu sso and triggers the login dialog on fresh
      install (LP: #674537, #708187)
  * debian/control, debian/rules:
    - we really don't depend on desktopcouch now
    - deps on ubuntu-sso-client now
    - transition to dh_python2
    - remove other deprecated deps
    - bump Standards-Version
 -- Didier Roche <email address hidden> Mon, 01 Aug 2011 12:30:21 +0200

Changed in oneconf (Ubuntu):
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.