Description of problem: imgbase base --remove=<BASE> doe not remove child layers. Version-Release number of selected component (if applicable): imgbased-0.8.11-0.1.el7ev.noarch How reproducible: 100% Steps to Reproduce: 1. imgbase base --remove=<BASE> Actual results: Child layer is not removed and other commands fails due to this inconsistency: # imgbase --debug base --remove=rhvh-4.0-0.20161116.0 # imgbase base --latest Traceback (most recent call last): File "/usr/lib64/python2.7/runpy.py", line 162, in _run_module_as_main "__main__", fname, loader, pkg_name) File "/usr/lib64/python2.7/runpy.py", line 72, in _run_code exec code in run_globals File "/usr/lib/python2.7/site-packages/imgbased/__main__.py", line 51, in <module> CliApplication() File "/usr/lib/python2.7/site-packages/imgbased/__init__.py", line 82, in CliApplication app.hooks.emit("post-arg-parse", args) File "/usr/lib/python2.7/site-packages/imgbased/hooks.py", line 120, in emit cb(self.context, *args) File "/usr/lib/python2.7/site-packages/imgbased/plugins/core.py", line 137, in post_argparse print(app.imgbase.latest_base()) File "/usr/lib/python2.7/site-packages/imgbased/imgbase.py", line 322, in latest_base return self.naming.last_base() File "/usr/lib/python2.7/site-packages/imgbased/naming.py", line 62, in last_base bases = self.bases() File "/usr/lib/python2.7/site-packages/imgbased/naming.py", line 50, in bases bases = sorted(self.tree()) File "/usr/lib/python2.7/site-packages/imgbased/naming.py", line 224, in tree bases[img.base.nvr].layers.append(img) KeyError: <NVR rhvh-4.0-0.20161116.0 /> Expected results: The base is removed including its layers
Created attachment 1249875 [details] lvs taken before the removal
Created attachment 1249876 [details] lvs taken after the removal
Created attachment 1249877 [details] imgbase debug logs
QE can reproduce this issue.
*** This bug has been marked as a duplicate of bug 1419535 ***