def get_binary_package(self, package): """ Get the DB entry for the binary package. Return None if it doesn't exist. """ try: return dict(Binary.load(package)) except KeyError: return None
def get_deb_info(self, package): """ Get a list of .debs for the given Binary package, otherwise None. """ pkg = Binary.load(package) source = pkg.get_source() public = config['public'] root = "{public}/{pool}/{arch}".format( public=public, pool=source['path'], arch=pkg['arch'], ) return {"root": root, "packages": pkg['binaries']}