<?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>11210</bug_id>
          
          <creation_ts>2017-03-22 12:30:08 +0000</creation_ts>
          <short_desc>tinfoil: parse_recipe() fails for multiconfig pns</short_desc>
          <delta_ts>2017-04-19 15:49:35 +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>unspecified</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>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>2.3 M4</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Patrick Ohly">patrick.ohly</reporter>
          <assigned_to name="Juro Bystricky">juro.bystricky</assigned_to>
          <cc>poky.bs.watcher</cc>
    
    <cc>poky.watcher</cc>
    
    <cc>ross.burton</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>71571</commentid>
    <comment_count>0</comment_count>
    <who name="Patrick Ohly">patrick.ohly</who>
    <bug_when>2017-03-22 12:30:08 +0000</bug_when>
    <thetext>Traceback (most recent call last):
  File &quot;/fast/work/meta-security-tools/scripts/sdl-whitelist-status.py&quot;, line 97, in &lt;module&gt;
    tinfoil.parse_recipe(&apos;multiconfig:qemuarm:gcc&apos;)
  File &quot;/fast/work/bitbake/lib/bb/tinfoil.py&quot;, line 350, in parse_recipe
    return self.parse_recipe_file(fn)
  File &quot;/fast/work/bitbake/lib/bb/tinfoil.py&quot;, line 373, in parse_recipe_file
    dscon = self.run_command(&apos;parseRecipeFile&apos;, fn, appends, appendlist)
  File &quot;/fast/work/bitbake/lib/bb/tinfoil.py&quot;, line 281, in run_command
    raise TinfoilCommandFailed(result[1])
bb.tinfoil.TinfoilCommandFailed: Traceback (most recent call last):
  File &quot;/fast/work/bitbake/lib/bb/command.py&quot;, line 81, in runCommand
    result = command_method(self, commandline)
  File &quot;/fast/work/bitbake/lib/bb/command.py&quot;, line 521, in parseRecipeFile
    appendfiles = command.cooker.collection.get_file_appends(fn)
  File &quot;/fast/work/bitbake/lib/bb/cooker.py&quot;, line 1961, in get_file_appends
    f = os.path.basename(fn)
  File &quot;/usr/lib/python3.4/posixpath.py&quot;, line 139, in basename
    i = p.rfind(sep) + 1
AttributeError: &apos;NoneType&apos; object has no attribute &apos;rfind&apos;

&apos;multiconfig:qemuarm:gcc&apos; is a valid pn because of:
$ cat conf/multiconfig/qemuarm.conf 
MACHINE = &quot;qemuarm&quot;
$ grep -e ^BBMULTICONFIG -e ^MACHINE conf/local.conf
MACHINE ?= &quot;intel-corei7-64&quot;
BBMULTICONFIG = &quot;qemuarm&quot;

Looks like fn = self.get_recipe_file(pn) fails to find the file name.

Note that there&apos;s also no error handling when passing some entirely invalid pn. tinfoil.parse_recipe(&apos;foobar&apos;) fails the same way.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>72114</commentid>
    <comment_count>1</comment_count>
    <who name="Juro Bystricky">juro.bystricky</who>
    <bug_when>2017-04-05 22:15:25 +0000</bug_when>
    <thetext>Sent two patches for a review:
http://lists.openembedded.org/pipermail/bitbake-devel/2017-April/008572.html
http://lists.openembedded.org/pipermail/bitbake-devel/2017-April/008573.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>72134</commentid>
    <comment_count>2</comment_count>
    <who name="Juro Bystricky">juro.bystricky</who>
    <bug_when>2017-04-06 14:45:04 +0000</bug_when>
    <thetext>patch not accepted, back to the drawing board...</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>72224</commentid>
    <comment_count>3</comment_count>
    <who name="Juro Bystricky">juro.bystricky</who>
    <bug_when>2017-04-10 18:11:07 +0000</bug_when>
    <thetext>sent patches updated according to feedback:
http://lists.openembedded.org/pipermail/bitbake-devel/2017-April/008618.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>72664</commentid>
    <comment_count>4</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2017-04-19 15:49:35 +0000</bug_when>
    <thetext>Merged in Bitbake e9c03fbfd7b057b28645affa263cb4aebfa24b04.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>