[pacman-dev] Little question regarding alpm
Aurelien Foret
aurelien at archlinux.org
Mon Feb 20 16:13:49 EST 2006
Joao Estevao wrote:
> I'm currently trying to write a front end in python and a python
> wrapper to alpm and I'm running into some problems.
>
> I can't seem to be able to install a package twice. All goes well the
> first time, but then I get this:
>
> DEBUG: closing database 'extra'
> DEBUG: freeing package cache for repository 'extra'
>
> Then I tought I might have to re-open the 'extra' db, so I close it
> and then I re-open it and get this:
>
> FLOW2: target 'alsaplayer' not found -- looking for provisions
>
> or sometimes I get :
>
> RuntimeError: transaction not initialized
>
> or sometimes it works.
>
> I guess my question is this. Why does alpm close the db and free the
> pkg cache when one installs some package(s)? Couldn't it refresh the
> db and the pkg cache?
>
> Thanks in advance and please correct me if I'm wrong.
To answer your question, the library is updating the cache each time a
package is installed or removed.
A database can only be closed if the frontend requested it
(alpm_db_unregister), or if the library resources are released
(alpm_release).
It would help to get the whole set of debug logs (set the PM_OPT_LOGMASK
option to 0xFF) to have a better idea of what's happening.
--
Aurelien
More information about the pacman-dev
mailing list