<?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>13583</bug_id>
          
          <creation_ts>2019-10-08 13:21:30 +0000</creation_ts>
          <short_desc>Make /usr/bin/python an alternatives?</short_desc>
          <delta_ts>2020-01-29 16:32:42 +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>OE-Core</product>
          <component>devtools / tool chain</component>
          <version>3.0</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>WONTFIX</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>3.1 M3</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Ross Burton">ross.burton</reporter>
          <assigned_to name="Ross Burton">ross.burton</assigned_to>
          <cc>bunk</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>randy.macleod</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>85256</commentid>
    <comment_count>0</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2019-10-08 13:21:30 +0000</bug_when>
    <thetext>If you just install python3 in an image, there is no /usr/bin/python binary because that is only shipped by python (2).

We should probably install that using alternatives instead.  Default to python2 for now, and migrate to py3 later.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>85259</commentid>
    <comment_count>1</comment_count>
    <who name="Adrian Bunk">bunk</who>
    <bug_when>2019-10-08 14:18:56 +0000</bug_when>
    <thetext>(In reply to comment #0)
&gt; If you just install python3 in an image, there is no /usr/bin/python binary
&gt; because that is only shipped by python (2).

While a change to PEP 394 just 3 months ago removed the wording that /usr/bin/python should not point to python3,[1] some distributions like Debian/Ubuntu might never provide a python -&gt; python3 symlink.

[1] https://github.com/python/peps/commit/ae932bd6fd2c493d7d64ce328a5293bac4c48884

&gt; We should probably install that using alternatives instead.  Default to
&gt; python2 for now, and migrate to py3 later.

With python3 installed, this would give a different python depending on whether or not there is some recipe from some layer installed that pulls in python2.

And &quot;migrate to py3 later&quot; would then break all recipes in layers that ship python2 scripts with #!/usr/bin/python shebangs.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>86143</commentid>
    <comment_count>2</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2020-01-29 16:32:42 +0000</bug_when>
    <thetext>What Adrian said makes sense.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>