# Make configuration
config = await self.config(local=True)
- log.debug("Launching Pakfire with configuration:\n%s", config.getvalue())
+ # Log action
+ log.debug("Launching Pakfire for %s:" % self.arch)
+ if config:
+ log.debug(config)
# Launch a new Pakfire instance (in a separate thread)
- async with self.backend.tempdir() as d:
- return await asyncio.to_thread(pakfire.Pakfire, ctx=ctx, path=d, arch=self.arch, conf=config)
+ async with self.backend.tempdir() as path:
+ return await asyncio.to_thread(
+ pakfire.Pakfire,
+ ctx = ctx,
+ path = path,
+ arch = self.arch,
+ config = config,
+ )
async def __aexit__(self, type, value, traceback):
pass
f = io.StringIO()
config.write(f)
- # Rewind the buffer
- f.seek(0)
-
- return f
+ return f.getvalue()
class PakfireLogger(object):