diff mbox series

[1.46,dunfell] layerindex: Fix bitbake-layers layerindex-show-depends command

Message ID 20240123194243.1760477-1-tim.orling@konsulko.com
State Accepted, archived
Commit 146cd25252ef065d09df0980b7dc670cb7e7b109
Headers show
Series [1.46,dunfell] layerindex: Fix bitbake-layers layerindex-show-depends command | expand

Commit Message

Tim Orling Jan. 23, 2024, 7:42 p.m. UTC
From: Diego Sueiro <diego.sueiro@arm.com>

Running 'bitbake-layers layerindex-show-depends meta-filesystems' fails with:
```
Traceback (most recent call last):
  File "<...>/poky/bitbake/bin/bitbake-layers", line 93, in <module>
    ret = main()
  File "<...>/poky/bitbake/bin/bitbake-layers", line 86, in main
    return args.func(args)
  File "<...>/poky/bitbake/lib/bblayers/layerindex.py", line 209, in do_layerindex_show_depends
    self.do_layerindex_fetch(args)
  File "<...>/poky/bitbake/lib/bblayers/layerindex.py", line 182, in do_layerindex_fetch
    args.shallow)
AttributeError: 'Namespace' object has no attribute 'shallow'
```

Initialize the shallow attribute to fix it.

Signed-off-by: Diego Sueiro <diego.sueiro@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
Backport from 71f095c14

 lib/bblayers/layerindex.py | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/lib/bblayers/layerindex.py b/lib/bblayers/layerindex.py
index 95b67a662..f64d18e81 100644
--- a/lib/bblayers/layerindex.py
+++ b/lib/bblayers/layerindex.py
@@ -206,6 +206,7 @@  class LayerIndexPlugin(ActionPlugin):
 """
         args.show_only = True
         args.ignore = []
+        args.shallow = True
         self.do_layerindex_fetch(args)
 
     def register_commands(self, sp):