[Yum-devel] [PATCH] Close history before downloads (maybe stop presto doing any damage).
Seth Vidal
skvidal at fedoraproject.org
Thu Feb 18 19:05:01 UTC 2010
On Thu, 18 Feb 2010, James Antill wrote:
> ---
> yum/__init__.py | 10 ++++++++++
> 1 files changed, 10 insertions(+), 0 deletions(-)
>
> diff --git a/yum/__init__.py b/yum/__init__.py
> index 06f6156..324a8ec 100644
> --- a/yum/__init__.py
> +++ b/yum/__init__.py
> @@ -1515,6 +1515,16 @@ class YumBase(depsolve.Depsolve):
> def adderror(po, msg):
> errors.setdefault(po, []).append(msg)
>
> + # We close the history DB here because some plugins (presto) use
> + # threads. And sqlite really doesn't like threads. And while I don't
> + # think it should matter, we've had some reports of history DB
> + # corruption, and it was implied that it happened just after C-c
> + # at download time and this is a safe thing to do.
> + # Note that manual testing shows that history is not connected by
> + # this point, from the cli with no plugins. So this really does
> + # nothing *sigh*.
> + self.history.close()
> +
> self.plugins.run('predownload', pkglist=pkglist)
> repo_cached = False
> remote_pkgs = []
> --
> 1.6.6
>
ACK
-sv
More information about the Yum-devel
mailing list