Bug 9148 - Cover variable references not being expanded in python functions
Summary: Cover variable references not being expanded in python functions
Status: RESOLVED FIXED
Alias: None
Product: BitBake User Manual
Classification: Documentation
Component: bitbake-manual (show other bugs)
Version: unspecified
Hardware: x86 Multiple
: Medium+ enhancement
Target Milestone: 2.1 M3
Assignee: Scott Rifenbark
QA Contact: Francisco Pedraza
URL:
Whiteboard: 3 March 2016: RESOLVED
Depends on:
Blocks:
 
Reported: 2016-02-21 21:04 UTC by Paul Eggleton
Modified: 2016-03-07 06:49 UTC (History)
3 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: Done (doc changes complete)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Paul Eggleton 2016-02-21 21:04:22 UTC
In "BitBake Style Python Functions", could you please add a note box with the following content:

Variable expressions e.g. ${X} are no longer expanded within Python functions. This is intentional in order to allow you to freely set variable values to expandable expressions without having them expanded prematurely. If you do wish to expand a variable within a Python function, use d.getVar("X", True), or for more complicated expressions use d.expand().
Comment 1 Scott Rifenbark 2016-02-23 17:23:18 UTC
Paul, 

See http://www.yoctoproject.org/docs/2.1/bitbake-user-manual/bitbake-user-manual.html#bitbake-style-python-functions and let me know if the note is okay.  Pretty much what you suggested.
Comment 2 Scott Rifenbark 2016-03-03 17:24:13 UTC
Paul, 

Check this out when you can... the bug got moved to Medium +.

Thanks, 
Scott
Comment 3 Paul Eggleton 2016-03-03 17:27:48 UTC
Yep, looks good to me.
Comment 4 Scott Rifenbark 2016-03-03 17:29:29 UTC
Thanks for the verification Paul.  Setting status to RESOLVED and moving the doc flag to "done."

Scott