From d4982e0e6d4b4fefb55043bb999784f5cfb2b686 Mon Sep 17 00:00:00 2001 From: Julian Andres Klode Date: Fri, 23 Jul 2010 16:32:54 +0200 Subject: * doc/conf.py: - Correctly handle non-digit characters in version (ignore everything after them). --- doc/source/conf.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'doc/source') diff --git a/doc/source/conf.py b/doc/source/conf.py index 05490da7..18c8642e 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -78,8 +78,13 @@ except KeyError: release = p2.communicate()[0] # Handle the alpha release scheme -release_raw = release.split("~")[0].split(".")[2] -if release_raw.isdigit() and int(release_raw) >= 90: +release_raw = "0" +for c in release.split("~")[0].split(".")[2]: + if not c.isdigit(): + break + release_raw += c + +if int(release_raw) >= 90: version_s = release.split("~")[0].split(".")[:3] # Set the version to 0.X.100 if the release is 0.X.9Y (0.7.90 => 0.7.100) # Use -- cgit v1.2.3 From d642c9ea22f5705acfcba79493f48293626771c3 Mon Sep 17 00:00:00 2001 From: Julian Andres Klode Date: Fri, 23 Jul 2010 16:37:13 +0200 Subject: * python/apt_pkgmodule.cc: - Bind pkgAcquire::Item::StatTransientNetworkError (Closes: #589010) --- debian/changelog | 2 ++ doc/source/library/apt_pkg.rst | 4 ++++ python/apt_pkgmodule.cc | 2 ++ 3 files changed, 8 insertions(+) (limited to 'doc/source') diff --git a/debian/changelog b/debian/changelog index c76efa37..cb747f14 100644 --- a/debian/changelog +++ b/debian/changelog @@ -6,6 +6,8 @@ python-apt (0.7.97) UNRELEASED; urgency=low * doc/conf.py: - Correctly handle non-digit characters in version (ignore everything after them). + * python/apt_pkgmodule.cc: + - Bind pkgAcquire::Item::StatTransientNetworkError (Closes: #589010) -- Julian Andres Klode Fri, 23 Jul 2010 16:14:39 +0200 diff --git a/doc/source/library/apt_pkg.rst b/doc/source/library/apt_pkg.rst index dd958959..b91790db 100644 --- a/doc/source/library/apt_pkg.rst +++ b/doc/source/library/apt_pkg.rst @@ -1381,6 +1381,10 @@ installation. The item is yet to be fetched. + .. attribute:: STAT_TRANSIENT_NETWORK_ERROR + + There was a network error. + .. class:: AcquireFile(owner, uri[, md5, size, descr, short_descr, destdir, destfile]) diff --git a/python/apt_pkgmodule.cc b/python/apt_pkgmodule.cc index a1e9ada0..cacbf77a 100644 --- a/python/apt_pkgmodule.cc +++ b/python/apt_pkgmodule.cc @@ -905,6 +905,8 @@ extern "C" void initapt_pkg() Py_BuildValue("i", pkgAcquire::Item::StatFetching)); PyDict_SetItemString(PyAcquireItem_Type.tp_dict, "STAT_DONE", Py_BuildValue("i", pkgAcquire::Item::StatDone)); + PyDict_SetItemString(PyAcquireItem_Type.tp_dict, "STAT_TRANSIENT_NETWORK_ERROR", + Py_BuildValue("i", pkgAcquire::Item::StatTransientNetworkError)); PyDict_SetItemString(PyAcquireItem_Type.tp_dict, "STAT_ERROR", Py_BuildValue("i", pkgAcquire::Item::StatError)); PyDict_SetItemString(PyAcquireItem_Type.tp_dict, "STAT_AUTH_ERROR", -- cgit v1.2.3 From 82ed2ce73fb57166d0e47f164f1f9bdc6c821389 Mon Sep 17 00:00:00 2001 From: Julian Andres Klode Date: Mon, 2 Aug 2010 15:31:42 +0200 Subject: doc/library/apt_pkg.rst: Document Configuration.dump(). --- debian/changelog | 2 ++ doc/source/library/apt_pkg.rst | 5 +++++ 2 files changed, 7 insertions(+) (limited to 'doc/source') diff --git a/debian/changelog b/debian/changelog index 14ad4bf5..73b3987e 100644 --- a/debian/changelog +++ b/debian/changelog @@ -9,6 +9,8 @@ python-apt (0.7.97) UNRELEASED; urgency=low after them). * python/apt_pkgmodule.cc: - Bind pkgAcquire::Item::StatTransientNetworkError (Closes: #589010) + * doc/library/apt_pkg.rst: + - Document Configuration.dump(). [ Michael Vogt ] * python/configuration.cc: diff --git a/doc/source/library/apt_pkg.rst b/doc/source/library/apt_pkg.rst index b91790db..81dafd54 100644 --- a/doc/source/library/apt_pkg.rst +++ b/doc/source/library/apt_pkg.rst @@ -1828,6 +1828,11 @@ Configuration and Command-line parsing Remove the option at *key* and all of its children. + .. method:: dump() -> str + + Return a string containing the values in the configuration object, + in the standard :manpage:`apt.conf(5)` format. + .. method:: exists(key) Check whether an option named *key* exists in the configuration. -- cgit v1.2.3