Jump to content

[Answered] How Can I Use Python 2.7?


Elusive

Recommended Posts

How can I run a script under Python 2.7? I am on Johnny. Are newer versions of Python only available on Stevie?

 

#! /usr/bin/env python
import sys
print ("Content-type: text/plain\n\n")
print (sys.version)

 

reports:

 

2.4.3 (#1, Jun 18 2012, 08:55:23)
[GCC 4.1.2 20080704 (Red Hat 4.1.2-52)]

 

#! /usr/bin/python2.4

 

also reports 2.4.3

 

The following all resulted in a HTTP 500 response:

 

#! /usr/bin/env python2.7
#! /usr/bin/python2.7
#! /usr/local/bin/python2.7
#! /bin/python2.7

#! /usr/bin/env python27
#! /usr/bin/python27
#! /usr/local/bin/python27
#! /bin/python27

#! /usr/bin/env python3.2
#! /usr/bin/python3.2
#! /usr/bin/env python32
#! /usr/bin/python32

 

 

Thanks!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...