summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2006-04-28 18:08:49 +0200
committerMichael Vogt <michael.vogt@ubuntu.com>2006-04-28 18:08:49 +0200
commit44f04eb81fa2fefaa766baa919cacd5dc90f5641 (patch)
tree5b683327e387e1d2fb5c576d106b7dd2fe4835eb
parent34eb7395b42df46fe9caf53d107d212e39a7cdf8 (diff)
downloadpython-apt-44f04eb81fa2fefaa766baa919cacd5dc90f5641.tar.gz
* DistUpgrade/Changelog: updated
* DistUpgrade/DistUpgradeControler.py: some FIXMEs added * DistUpgrade/DistUpgradeViewGtk.py: - dont report dpkg timeouts (no activity on terinal) over and over again
-rw-r--r--DistUpgrade/Changelog7
-rw-r--r--DistUpgrade/DistUpgradeControler.py8
-rw-r--r--DistUpgrade/DistUpgradeViewGtk.py5
-rw-r--r--DistUpgrade/TODO2
4 files changed, 20 insertions, 2 deletions
diff --git a/DistUpgrade/Changelog b/DistUpgrade/Changelog
index 4a69f51f..c450d99d 100644
--- a/DistUpgrade/Changelog
+++ b/DistUpgrade/Changelog
@@ -1,3 +1,10 @@
+2006-04-28:
+ - add more sanity checking, if no valid mirror is found in the
+ sources.list ask for "dumb" rewrite
+ - if nothing valid was found after a dumb rewrite, add official
+ sources
+ - don't report install TIMEOUT over and over in the log
+ - report what package caused a install TIMEOUT
2006-04-27:
- add a additonal sanity check after the rewriting of the sources.list
(check for BaseMetaPkgs still in the cache)
diff --git a/DistUpgrade/DistUpgradeControler.py b/DistUpgrade/DistUpgradeControler.py
index c486a407..c89f6a34 100644
--- a/DistUpgrade/DistUpgradeControler.py
+++ b/DistUpgrade/DistUpgradeControler.py
@@ -149,7 +149,9 @@ class DistUpgradeControler(object):
"will cancel.") % (self.fromDist, self.toDist)
if not self._view.askYesNoQuestion(prim, secon):
self.abort()
- # add some defaults
+
+ # add some defaults here
+ # FIXME: find mirror here
uri = "http://archive.ubuntu.com/ubuntu"
comps = ["main","restricted"]
self.sources.add("deb", uri, self.toDist, comps)
@@ -389,6 +391,10 @@ class DistUpgradeControler(object):
# if not something went seriously wrong
for pkg in self.config.getlist("Distro","BaseMetaPkgs"):
if not self.cache.has_key(pkg):
+ # FIXME: we could offer to add default source entries here,
+ # but we need to be careful to not duplicate them
+ # (i.e. the error here could be something else than
+ # missing sources entires but network errors etc)
logging.error("No '%s' after sources.list rewrite+update")
self._view.error(_("Inavlid package information"),
_("After your package information was "
diff --git a/DistUpgrade/DistUpgradeViewGtk.py b/DistUpgrade/DistUpgradeViewGtk.py
index 69990fd5..81cd9bba 100644
--- a/DistUpgrade/DistUpgradeViewGtk.py
+++ b/DistUpgrade/DistUpgradeViewGtk.py
@@ -212,6 +212,7 @@ class GtkInstallProgressAdapter(InstallProgress):
# start showing when we gathered some data
if percent > 1.0:
self.last_activity = time.time()
+ self.activity_timeout_reported = False
delta = self.last_activity - self.start_time
time_per_percent = (float(delta)/percent)
eta = (100.0 - self.percent) * time_per_percent
@@ -242,7 +243,9 @@ class GtkInstallProgressAdapter(InstallProgress):
# check about terminal activity
if self.last_activity > 0 and \
(self.last_activity + self.TIMEOUT_TERMINAL_ACTIVITY) < time.time():
- logging.warning("no activity on terminal for %s seconds" % self.TIMEOUT_TERMINAL_ACTIVITY)
+ if not self.activity_timeout_reported:
+ logging.warning("no activity on terminal for %s seconds (%s)" % (self.TIMEOUT_TERMINAL_ACTIVITY, self.label_status.get_text())
+ self.activity_timeout_reported = True
self.parent.expander_terminal.set_expanded(True)
while gtk.events_pending():
gtk.main_iteration()
diff --git a/DistUpgrade/TODO b/DistUpgrade/TODO
index c32e6bc3..d3f3ad66 100644
--- a/DistUpgrade/TODO
+++ b/DistUpgrade/TODO
@@ -11,7 +11,9 @@ MUSTFIX:
are commented out
(or for sources that can't be identified and rewrite ask the user
what to do by just s/breezy/dapper/g?)
+ [Done]
* inform about commented out sources
+ [Done]
* fix "no activity for 120s warning" being repeated every sec in the logs
* use the dialog frontend (for debconf) and detect the ansi sequence that
clear the screen and expand the terminal then