<?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>11772</bug_id>
          
          <creation_ts>2017-07-07 12:28:34 +0000</creation_ts>
          <short_desc>[PATCH] event: temporarily disable verbose logs</short_desc>
          <delta_ts>2021-11-11 17:17:28 +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>BitBake</product>
          <component>bitbake</component>
          <version>2.5</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>OBSOLETE</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard> </status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>4.99</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Enrico Scholz">enrico.scholz</reporter>
          <assigned_to name="Richard Purdie">richard.purdie</assigned_to>
          <cc>poky.bs.watcher</cc>
    
    <cc>poky.watcher</cc>
          
          
          <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>74861</commentid>
    <comment_count>0</comment_count>
      <attachid>3860</attachid>
    <who name="Enrico Scholz">enrico.scholz</who>
    <bug_when>2017-07-07 12:28:34 +0000</bug_when>
    <thetext>Created attachment 3860
patch

Because stderr of event handlers is directly printed to the console,
this will pollute output when using e.g. &apos;buildhistory&apos; which calls a
shell function.

This can be reproduced/demonstrated e.g. by setting

  BB_VERBOSE_LOGS = &quot;1&quot;
  INHERIT += &quot;buildhistory&quot;

Patch disables &apos;set -x&apos; temporarily while executing the event handler.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>91883</commentid>
    <comment_count>1</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2021-11-03 13:06:05 +0000</bug_when>
    <thetext>Sorry this has taken so long to get back to, I do keep looking at it periodically and the world has changed a bit since the bug was opened.

I think part of the confusion was the two different behaviours of verbose logs previously. The bitbake -v option would have things appear on the console, BB_VERBOSE_LOGS would have things appear in the logfiles. I generally read the summary of the bug as the &quot;-v&quot; option and this meant I didn&apos;t really see the issue of the event shell output on the console when there was already so much output.

Since the bug is about BB_VERBOSE_LOGS, I think the issue was the event handler data appearing on the console when there wasn&apos;t anything else there?

The good news is that bitbake&apos;s logging has changed in the intervening time. The buildhistory event handler output now goes to the bitbake-cookerdaemon log file which I think is an appropriate interpretation of the option. The console remains clear.

Would you agree the patch is therefore now obsolete and not needed?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>91979</commentid>
    <comment_count>2</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2021-11-11 17:17:28 +0000</bug_when>
    <thetext>No longer an issue as per Comment 1.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>3860</attachid>
            <date>2017-07-07 12:28:34 +0000</date>
            <delta_ts>2017-07-07 12:28:34 +0000</delta_ts>
            <desc>patch</desc>
            <filename>0005-event-temporarily-disable-verbose-logs.patch</filename>
            <type>text/plain</type>
            <size>1452</size>
            <attacher name="Enrico Scholz">enrico.scholz</attacher>
            
              <data encoding="base64">RnJvbSA3MGJlMWZjMWQ2NDk4ZTQ4NzE1ZDllYmVmMzQ2ZTgzNmNhNWQ4NGUyIE1vbiBTZXAgMTcg
MDA6MDA6MDAgMjAwMQpGcm9tOiBFbnJpY28gU2Nob2x6IDxlbnJpY28uc2Nob2x6QHNpZ21hLWN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iAgICAgICAgIGJ1
aWx0aW5zWydkJ10gPSBkCiAgICAgICAgIGFkZGVkZCA9IFRydWUKKyAgICBvbGRfdmVyYm9zZSA9
IGJiLm1zZy5sb2dnZXJWZXJib3NlTG9ncwogICAgIHRyeToKKyAgICAgICAgYmIubXNnLmxvZ2dl
clZlcmJvc2VMb2dzID0gRmFsc2UKICAgICAgICAgcmV0ID0gaGFuZGxlcihldmVudCkKICAgICBl
eGNlcHQgKGJiLnBhcnNlLlNraXBSZWNpcGUsIGJiLkJCSGFuZGxlZEV4Y2VwdGlvbik6CiAgICAg
ICAgIHJhaXNlCkBAIC0xMTYsNiArMTE4LDcgQEAgZGVmIGV4ZWN1dGVfaGFuZGxlcihuYW1lLCBo
YW5kbGVyLCBldmVudCwgZCk6CiAgICAgICAgICAgICBsb2dnZXIuZXJyb3IoIkV4ZWN1dGlvbiBv
ZiBldmVudCBoYW5kbGVyICclcycgZmFpbGVkIiAlIG5hbWUpCiAgICAgICAgIHJhaXNlCiAgICAg
ZmluYWxseToKKyAgICAgICAgYmIubXNnLmxvZ2dlclZlcmJvc2VMb2dzID0gb2xkX3ZlcmJvc2UK
ICAgICAgICAgZGVsIGV2ZW50LmRhdGEKICAgICAgICAgaWYgYWRkZWRkOgogICAgICAgICAgICAg
ZGVsIGJ1aWx0aW5zWydkJ10KLS0KMi45LjQK
</data>

          </attachment>
      

    </bug>

</bugzilla>