<div dir="ltr"><div>Not sure about what leftover you're referring to... the commit message is not right ?<br><br><br></div>Alex<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Nov 15, 2013 at 11:28 AM, Richard Purdie <span dir="ltr"><<a href="mailto:richard.purdie@linuxfoundation.org" target="_blank">richard.purdie@linuxfoundation.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Thu, 2013-11-14 at 13:56 +0000, Alex DAMIAN wrote:<br>
> From: Alexandru DAMIAN <<a href="mailto:alexandru.damian@intel.com">alexandru.damian@intel.com</a>><br>
><br>
> In order to track the file where a configuration<br>
> variable was defined, this patch bring these changes:<br>
><br>
> * a new feature is defined in CookerFeatures, named<br>
> BASEDATASTORE_TRACKING. When a UI requests BASEDATASTORE_TRACKING,<br>
> the base variable definition are tracked when configuration<br>
> is parsed.<br>
><br>
> * getAllKeysWithFlags now includes variable history in the<br>
> data dump<br>
><br>
> * toaster_ui.py will record the operation, file path<br>
> and line number where the variable was changes<br>
><br>
> * toaster Simple UI will display the file path<br>
> and line number for Configuration page<br>
><br>
> There is a change in the models to accomodate the recording<br>
> of variable change history.<br>
><br>
> [YOCTO #5227]<br>
><br>
> Signed-off-by: Alexandru DAMIAN <<a href="mailto:alexandru.damian@intel.com">alexandru.damian@intel.com</a>><br>
> ---<br>
> lib/bb/cooker.py | 15 ++++++++++++---<br>
> lib/bb/cookerdata.py | 1 +<br>
> lib/bb/ui/buildinfohelper.py | 14 ++++++++++----<br>
> lib/bb/ui/toasterui.py | 2 +-<br>
> lib/toaster/bldviewer/templates/configuration.html | 6 ++++--<br>
> lib/toaster/orm/models.py | 6 +++++-<br>
> 6 files changed, 33 insertions(+), 11 deletions(-)<br>
><br>
> diff --git a/lib/bb/cooker.py b/lib/bb/cooker.py<br>
> index 0580cd5..4c9067b 100644<br>
> --- a/lib/bb/cooker.py<br>
> +++ b/lib/bb/cooker.py<br>
> @@ -81,7 +81,7 @@ class SkippedPackage:<br>
><br>
><br>
> class CookerFeatures(object):<br>
> - _feature_list = [HOB_EXTRA_CACHES, SEND_DEPENDS_TREE] = range(2)<br>
> + _feature_list = [HOB_EXTRA_CACHES, SEND_DEPENDS_TREE, BASEDATASTORE_TRACKING] = range(3)<br>
><br>
> def __init__(self):<br>
> self._features=set()<br>
> @@ -177,6 +177,9 @@ class BBCooker:<br>
> self.data.disableTracking()<br>
><br>
> def loadConfigurationData(self):<br>
> + if CookerFeatures.BASEDATASTORE_TRACKING in self.featureset:<br>
> + self.enableDataTracking()<br>
> +<br>
> self.initConfigurationData()<br>
> self.databuilder.parseBaseConfiguration()<br>
> self.data = self.databuilder.data<br>
> @@ -189,6 +192,10 @@ class BBCooker:<br>
> bb.data.update_data(self.event_data)<br>
> bb.parse.init_parser(self.event_data)<br>
><br>
> + if CookerFeatures.BASEDATASTORE_TRACKING in self.featureset:<br>
> + self.disableDataTracking()<br>
> +<br>
> +<br>
> def modifyConfigurationVar(self, var, val, default_file, op):<br>
> if op == "append":<br>
> self.appendConfigurationVar(var, val, default_file)<br>
> @@ -320,7 +327,6 @@ class BBCooker:<br>
> open(confpath, 'w').close()<br>
><br>
> def parseConfiguration(self):<br>
> -<br>
> # Set log file verbosity<br>
> verboselogs = bb.utils.to_boolean(self.data.getVar("BB_VERBOSE_LOGS", "0"))<br>
> if verboselogs:<br>
> @@ -1175,7 +1181,10 @@ class BBCooker:<br>
> try:<br>
> v = self.data.getVar(k, True)<br>
> if not k.startswith("__") and not isinstance(v, bb.data_smart.DataSmart):<br>
> - dump[k] = { 'v' : v }<br>
> + dump[k] = {<br>
> + 'v' : v ,<br>
> + 'history' : self.data.varhistory.variable(k),<br>
> + }<br>
> for d in flaglist:<br>
> dump[k][d] = self.data.getVarFlag(k, d)<br>
> except Exception as e:<br>
> diff --git a/lib/bb/cookerdata.py b/lib/bb/cookerdata.py<br>
> index e640ed0..1cc7bc2 100644<br>
> --- a/lib/bb/cookerdata.py<br>
> +++ b/lib/bb/cookerdata.py<br>
> @@ -127,6 +127,7 @@ class CookerConfiguration(object):<br>
> self.dump_signatures = False<br>
> self.dry_run = False<br>
> self.tracking = False<br>
> + self.server_only = False<br>
><br>
> self.env = {}<br>
><br>
<br>
</div></div>Patch looks ok in general but I think the above is leftover and<br>
unneeded?<br>
<br>
Cheers,<br>
<br>
Richard<br>
<br>
</blockquote></div><br><br clear="all"><br>-- <br><div dir="ltr">Alex Damian<div>Yocto Project<br></div><div>SSG / OTC </div></div>
</div>