Hi,

Am 23.05.2020 um 22:08 schrieb Michał Górny:
On Sat, 2020-05-23 at 22:02 +0200, magic-gen...@damage.devloop.de wrote:
I rewrote e-file in python by using the portage API [1]. But loading the
API slows down the whole script. Is there any way to speed up my
implementation? Have I done something fundamentally wrong?

My only suggestion would be to use pkgcore instead of portage.  It is
compatible at configuration/data format level, so your script should
work out of the box for Portage users.

Which makes me feel I did something fundamentally wrong :)

I used "portage.db['/']['vartree'].dbapi" and "portage.db['/']['porttree'].dbapi" to get the API for installed (vartree) and available (porttree) packages. This is not available ing pkgcore. I haven't found a quick guide on how to use pkgcore but I will have a further look.

Thanks
Daniel

Reply via email to