FAQ
My brain is running in n00b mode this morning...must find coffee.

I upgraded python this morning and entering python from the command
line runs the old version.

Just looked and it appears the old version is in /usr/bin while the
new one is in /usr/local/bin/

Besides changing the path order, how do I ensure it runs the new
version? I'm sure I'll bang my head on the desk in shame as soon as
I'm reminded.

Thanks.

Search Discussions

  • Chris Rebert at Jul 18, 2009 at 5:26 pm

    On Sat, Jul 18, 2009 at 10:25 AM, Tim Edwardswrote:
    My brain is running in n00b mode this morning...must find coffee.

    I upgraded python this morning and entering python from the command
    line runs the old version.
    Which OS? How did you install it?

    Cheers,
    Chris
  • Tim Edwards at Jul 18, 2009 at 5:37 pm
    Which OS? How did you install it?
    Sorry (see I need that coffee)

    Installed on redhat from source
  • Lie Ryan at Jul 18, 2009 at 5:58 pm

    Tim Edwards wrote:
    Which OS? How did you install it?
    Sorry (see I need that coffee)

    Installed on redhat from source
    You should consult the distro's (i.e. RedHat's) documentation/mailing
    list about changing the default python interpreter. In most cases, you
    will need to make sure all python-related packages are compatible with
    the new python version. In popular distros, there should be a script
    that will do that for you.
  • Tim Edwards at Jul 18, 2009 at 7:35 pm

    You should consult the distro's (i.e. RedHat's) documentation/mailing
    list about changing the default python interpreter. In most cases, you
    will need to make sure all python-related packages are compatible with
    the new python version. In popular distros, there should be a script
    that will do that for you.
    Thanks, I'll look into that.
  • Christian Heimes at Jul 18, 2009 at 5:33 pm

    Tim Edwards wrote:
    Besides changing the path order, how do I ensure it runs the new
    version? I'm sure I'll bang my head on the desk in shame as soon as
    I'm reminded.
    hash -r

    Christian
  • Tim Edwards at Jul 18, 2009 at 5:54 pm

    Besides changing the path order, how do I ensure it runs the new
    version? I'm sure I'll bang my head on the desk in shame as soon as
    I'm reminded.
    hash -r
    Thanks.
  • Aahz at Jul 18, 2009 at 11:18 pm
    In article <mailman.3369.1247937914.8015.python-list at python.org>,
    Tim Edwards wrote:
    I upgraded python this morning and entering python from the command
    line runs the old version.

    Just looked and it appears the old version is in /usr/bin while the
    new one is in /usr/local/bin/

    Besides changing the path order, how do I ensure it runs the new
    version? I'm sure I'll bang my head on the desk in shame as soon as
    I'm reminded.
    You probably want to create an alias for command-line usage; scripts
    should use the full path to the interpreter you want.
    --
    Aahz (aahz at pythoncraft.com) <*> http://www.pythoncraft.com/

    "The volume of a pizza of thickness 'a' and radius 'z' is
    given by pi*z*z*a"

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppython-list @
categoriespython
postedJul 18, '09 at 5:25p
activeJul 18, '09 at 11:18p
posts8
users5
websitepython.org

People

Translate

site design / logo © 2022 Grokbase