<?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>3768</bug_id>
          
          <creation_ts>2013-01-22 07:45:09 +0000</creation_ts>
          <short_desc>smart: --yaml option doesn&apos;t work</short_desc>
          <delta_ts>2013-02-16 19:23:11 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>11</classification_id>
          <classification>Runtime</classification>
          <product>Package Management Issues</product>
          <component>package-management-issues</component>
          <version>1.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>Medium</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>1.4 M4</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Yi Zhao">yi.zhao</reporter>
          <assigned_to name="Paul Eggleton">bluelightning</assigned_to>
          <cc>bluelightning</cc>
    
    <cc>bogdan.a.marinescu</cc>
    
    <cc>hongxu.jia</cc>
    
    <cc>liang.li2</cc>
    
    <cc>mark.hatle</cc>
    
    <cc>Qi.Chen</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>---</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>29014</commentid>
    <comment_count>0</comment_count>
    <who name="Yi Zhao">yi.zhao</who>
    <bug_when>2013-01-22 07:45:09 +0000</bug_when>
    <thetext>Image location: http://autobuilder.yoctoproject.org/pub/nightly/20130115-2/
Tree/Branch: poky/master
Git Rev: 9eb88ceb39b7d0b8ddc6487e61ce8edadef10ec4

Some smart commands have the --yaml option, but this option doesn&apos;t work.

##############
root@qemumips:~# smart channel --yaml
Traceback (most recent call last):
  File &quot;/usr/bin/smart&quot;, line 200, in &lt;module&gt;
    main(sys.argv[1:])
  File &quot;/usr/bin/smart&quot;, line 173, in main
    exitcode = iface.run(opts.command, opts.argv)
  File &quot;/usr/lib/python2.7/site-packages/smart/interface.py&quot;, line 53, in run
    result = _command.main(self._ctrl, opts)
  File &quot;/usr/lib/python2.7/site-packages/smart/commands/channel.py&quot;, line 342, in main
    import yaml
ImportError: No module named yaml
root@qemumips:~# 

root@qemumips:~# smart config --yaml
Traceback (most recent call last):
  File &quot;/usr/bin/smart&quot;, line 200, in &lt;module&gt;
    main(sys.argv[1:])
  File &quot;/usr/bin/smart&quot;, line 173, in main
    exitcode = iface.run(opts.command, opts.argv)
  File &quot;/usr/lib/python2.7/site-packages/smart/interface.py&quot;, line 53, in run
    result = _command.main(self._ctrl, opts)
  File &quot;/usr/lib/python2.7/site-packages/smart/commands/config.py&quot;, line 140, in main
    import yaml
ImportError: No module named yaml
root@qemumips:~# 

##############</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>29019</commentid>
    <comment_count>1</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2013-01-22 08:55:34 +0000</bug_when>
    <thetext>This is simply because the yaml python module isn&apos;t installed. I wouldn&apos;t consider this core functionality, so the question is do we want to add a dependency just for the sake of enabling this option?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>29181</commentid>
    <comment_count>2</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2013-01-25 10:55:34 +0000</bug_when>
    <thetext>Changing to NEEDINFO, see my above comment</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>29208</commentid>
    <comment_count>3</comment_count>
    <who name="Mark Hatle">mark.hatle</who>
    <bug_when>2013-01-25 17:31:20 +0000</bug_when>
    <thetext>yaml is a pretty common way of exporting information from an RPM repository.

We likely should package up the yaml python module.. and then add a test in smart to see if it is installed.

That way it works if the user needs it, but it&apos;s disabled (to save space) for the normal case.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>29209</commentid>
    <comment_count>4</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2013-01-25 17:42:16 +0000</bug_when>
    <thetext>Sounds like a sensible approach to me - thanks.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>29669</commentid>
    <comment_count>5</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2013-02-08 09:46:49 +0000</bug_when>
    <thetext>It turns out there&apos;s a python-pyyaml recipe in meta-oe, it just needed an update; I have sent a patch to update it and the libyaml recipe that is also there. I&apos;ve also sent an OE-Core patch to ask the user to install PyYAML if it can&apos;t be imported instead of printing a python backtrace.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>29711</commentid>
    <comment_count>6</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2013-02-11 15:28:52 +0000</bug_when>
    <thetext>The OE-Core/Poky part of this patch is merged:

http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=0d85fa531b03f0e7b3ad3d2a5a4d92293b43b8ff

The meta-oe part is still pending.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>29880</commentid>
    <comment_count>7</comment_count>
    <who name="Paul Eggleton">bluelightning</who>
    <bug_when>2013-02-16 19:23:11 +0000</bug_when>
    <thetext>libyaml/python-pyyaml changes have now been merged into meta-oe:

http://cgit.openembedded.org/meta-openembedded/commit/?id=9c824550785d96dda0e6aeb4a2a37bb2c30dc125
http://cgit.openembedded.org/meta-openembedded/commit/?id=f976a44387f45ac5ede7d74d511bef1228599597</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>