Bug 11686

Summary: sanity.bbclass: bblayers.conf upgrade not happening on base config parse errors
Product: [Build System, Metadata & Runtime] OE-Core Reporter: Patrick Ohly <patrick.ohly>
Component: coreAssignee: Richard Purdie <richard.purdie>
Status: NEW --- QA Contact: yeoh ee peng <ee.peng.yeoh>
Severity: normal    
Priority: Medium CC: ee.peng.yeoh, meta.mr.watcher, meta.watcher, randy.macleod, sgw
Version: unspecified   
Target Milestone: 6.99   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description Patrick Ohly 2017-06-19 06:33:43 UTC
Consider this scenario:

- a developer is at LCONF_VERSION 1, using my-distro.conf as distro
- my-distro adds a new layer foo and in my-distro.conf adds a
  "require foo.inc" from that layer
- the developer updates the meta data

The expected outcome is that, as usual, the developer is told to update his out-dated bblayers.conf.

What happens instead is that base config parsing fails with a fatal error because of the missing foo.inc. It's missing because the developer doesn't have the "foo" layer in is old bblayers.conf.

This particular case can be worked around with "include foo.inc", but that's just a workaround and more fragile because it also doesn't error out when the file disappears unintentionally.

We just hit that case in refkit (see conf/distro/include/flatpak.inc in enable-refkit-config.inc).

Should the "base configuration parsed" event also be triggered in the failure case, with some special logic that the build aborts unless the event handler throws a "reparse" exception?
Comment 1 Randy MacLeod 2023-10-24 14:24:52 UTC
Bulk move from 4.99 or 0.00 to 5.99
Comment 2 Randy MacLeod 2025-12-18 16:27:33 UTC
Some improvements due to bitbake-setup but still work to do.