Bug 14869

Summary: proper closedown of a variable (e.g. SRC_URI) is not properly terminated
Product: [Build System, Metadata & Runtime] BitBake Reporter: Frans Meulenbroeks <fransmeulenbroeks>
Component: bitbakeAssignee: Richard Purdie <richard.purdie>
Status: RESOLVED WORKSFORME QA Contact:
Severity: normal    
Priority: Medium+ CC: poky.bs.watcher, poky.watcher, randy.macleod
Version: unspecified   
Target Milestone: 4.2 M3   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description Frans Meulenbroeks 2022-08-04 10:10:59 UTC
It happens for me every once in a while that I add a line to a multiline SRC_URI or DEPENDS and forget the trailing \
In that case bitbake crashes with SIGTERM, but the lock file is still there

Can we catch this situation and give a proper error message and remove the lock file please?
Comment 1 Richard Purdie 2022-11-28 10:51:05 UTC
I tried to reproduce this with master, removing the "\" from the middle of SRC_URI for acpid:

$ bitbake bash
Loading cache: 100% |#######################################################################################################################################| Time: 0:00:01
Loaded 1688 entries from dependency cache.
ERROR: ParseError at /media/build/poky/meta/recipes-bsp/acpid/acpid.inc:14: unparsed line: 'SRC_URI = "${SOURCEFORGE_MIRROR}/acpid2/acpid-${PV}.tar.xz            file://init'
ERROR: Parsing halted due to errors, see error messages above

and I could rerun the command repeatedly, always giving the same error message.

Which release are you seeing the issue in? I suspect we fixed something in recent releases in this area, certainly master seems to work fine.

Please reopen if you can give us a way to reproduce this on master.