<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>12194</bug_id>
          
          <creation_ts>2017-10-05 19:58:05 +0000</creation_ts>
          <short_desc>Toaster server lost &quot;toaster.conf&quot; environment, user settings lost</short_desc>
          <delta_ts>2017-10-09 17:59:49 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>Toaster</product>
          <component>toaster</component>
          <version>2.4</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>High</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>2.4 M4</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="David Reyna">david.reyna</reporter>
          <assigned_to name="David Reyna">david.reyna</assigned_to>
          <cc>jessica.zhang</cc>
    
    <cc>poky.bs.watcher</cc>
    
    <cc>poky.watcher</cc>
    
    <cc>stanciux.mihail</cc>
          
          <qa_contact name="Libertad">libertad.gonzalez.de.la.cruz</qa_contact>
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>No (bug/feature does not impact docs)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>77403</commentid>
    <comment_count>0</comment_count>
    <who name="David Reyna">david.reyna</who>
    <bug_when>2017-10-05 19:58:05 +0000</bug_when>
    <thetext>The builds run by Toaster are missing the crucial &quot;toaster.conf&quot; and &quot;toaster-bblayers.conf&quot;, and thus lose all customer settings.

Toaster had been passing in these files when the bb server was started in &apos;--server-only&apos; mode, and prior to the recent server changes those environment settings were preserved when the subsequent build call was made.

Apparently now either those environment settings are no longer persistent, or when Toaster connects to the server the second time with the new port number, that resulting environment is un-connected to the original environment.

The problem was not observed prior to now since there were no build failures, just silent errors as all user changes (like MACHINE) were ignored.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>77404</commentid>
    <comment_count>1</comment_count>
    <who name="David Reyna">david.reyna</who>
    <bug_when>2017-10-05 20:00:14 +0000</bug_when>
    <thetext>Here is the proposed patch:

diff --git a/bitbake/lib/toaster/bldcontrol/localhostbecontroller.py b/bitbake/l
index a2ca95b..ab9d9c0 100644
--- a/bitbake/lib/toaster/bldcontrol/localhostbecontroller.py
+++ b/bitbake/lib/toaster/bldcontrol/localhostbecontroller.py
@@ -381,9 +381,10 @@ class LocalhostBEController(BuildEnvironmentController):
         local_bitbake = os.path.join(os.path.dirname(os.getenv(&apos;BBBASEDIR&apos;)),
                                      &apos;bitbake&apos;)
         self._shellcmd([&apos;bash -c \&quot;(TOASTER_BRBE=&quot;%s&quot; BBSERVER=&quot;0.0.0.0:%s&quot; &apos;
-                        &apos;%s %s -u toasterui --token=&quot;&quot; &gt;&gt;%s 2&gt;&amp;1;&apos;
+                        &apos;%s %s -u toasterui  --read %s --read %s --token=&quot;&quot; &gt;&gt;%
                         &apos;BITBAKE_UI=&quot;knotty&quot; BBSERVER=0.0.0.0:%s %s -m)&amp;\&quot;&apos; \
-                        % (brbe, self.be.bbport, local_bitbake, bbtargets, log,
+                        % (brbe, self.be.bbport, local_bitbake, bbtargets, conf
+                        self.be.bbport, bitbake,)],
                         builddir, nowait=True)
 
         logger.debug(&apos;localhostbecontroller: Build launched, exiting. &apos;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>77410</commentid>
    <comment_count>2</comment_count>
    <who name="David Reyna">david.reyna</who>
    <bug_when>2017-10-06 03:35:48 +0000</bug_when>
    <thetext>Paul Eggleton has confirmed that the change in behaviour was intentional - bitbake will clear out any prefiles specified in a previous invocation even if that was the invocation that started the server. 

This behaviour wasn&apos;t well-defined and so it was working by accident beforehand.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>77466</commentid>
    <comment_count>3</comment_count>
    <who name="David Reyna">david.reyna</who>
    <bug_when>2017-10-09 17:59:49 +0000</bug_when>
    <thetext>commit 3eb62b0d700a05c923c5cd96f0c3377202c1e0da
    
(Bitbake rev: fa767d85f19a7af92a44fe11fdfb38633009ad71)</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>