mirror of
git://git.yoctoproject.org/layerindex-web.git
synced 2025-07-19 20:59:01 +02:00
layerindex: Update tinfoil to call shutdown method
The new client/server API of tinfoil requires explicit call of shutdown method to send the event for finalize cooker process. Also in update_layer remove the databuilder and cache instance now isn't needed. [YOCTO #10863] Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
This commit is contained in:
parent
c1ba5f65f1
commit
cb6f6b50d0
|
@ -231,6 +231,7 @@ def main():
|
||||||
|
|
||||||
outp = generate_patches(tinfoil, fetchdir, changeset, sys.argv[2])
|
outp = generate_patches(tinfoil, fetchdir, changeset, sys.argv[2])
|
||||||
finally:
|
finally:
|
||||||
|
tinfoil.shutdown()
|
||||||
utils.unlock_file(lockfile)
|
utils.unlock_file(lockfile)
|
||||||
|
|
||||||
if outp:
|
if outp:
|
||||||
|
|
|
@ -89,6 +89,8 @@ def main():
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logger.info("Unable to read %s: %s", fullpath, str(e))
|
logger.info("Unable to read %s: %s", fullpath, str(e))
|
||||||
|
|
||||||
|
tinfoil.shutdown()
|
||||||
|
|
||||||
sys.exit(0)
|
sys.exit(0)
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -34,12 +34,6 @@ def _setup_tinfoil(bitbakepath, enable_tracking):
|
||||||
tinfoil.cooker.enableDataTracking()
|
tinfoil.cooker.enableDataTracking()
|
||||||
tinfoil.prepare(config_only = True)
|
tinfoil.prepare(config_only = True)
|
||||||
|
|
||||||
# XXX: Setup databuilder
|
|
||||||
tinfoil.databuilder = bb.cookerdata.CookerDataBuilder(tinfoil.config)
|
|
||||||
tinfoil.databuilder.parseBaseConfiguration()
|
|
||||||
|
|
||||||
tinfoil.cache = bb.cache.NoCache(tinfoil.databuilder)
|
|
||||||
|
|
||||||
return tinfoil
|
return tinfoil
|
||||||
|
|
||||||
def _parse_layer_conf(layerdir, data):
|
def _parse_layer_conf(layerdir, data):
|
||||||
|
|
|
@ -201,6 +201,7 @@ def main():
|
||||||
transaction.rollback()
|
transaction.rollback()
|
||||||
finally:
|
finally:
|
||||||
transaction.leave_transaction_management()
|
transaction.leave_transaction_management()
|
||||||
|
tinfoil.shutdown()
|
||||||
|
|
||||||
shutil.rmtree(tempdir)
|
shutil.rmtree(tempdir)
|
||||||
sys.exit(0)
|
sys.exit(0)
|
||||||
|
|
|
@ -611,6 +611,7 @@ def main():
|
||||||
import traceback
|
import traceback
|
||||||
traceback.print_exc()
|
traceback.print_exc()
|
||||||
|
|
||||||
|
tinfoil.shutdown()
|
||||||
shutil.rmtree(tempdir)
|
shutil.rmtree(tempdir)
|
||||||
sys.exit(0)
|
sys.exit(0)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user