Invalid Syntax Error with Python 2.4

Bug #234540 reported by Derek Morton
4
Affects Status Importance Assigned to Milestone
command-not-found (Ubuntu)
Fix Released
Undecided
Colin Watson

Bug Description

Binary package hint: command-not-found

Ubuntu 8.04
command-not-found version: 0.2.17ubuntu1

Command-not-found errors with a syntax error when Python 2.4 is used as the Python interpreter, instead of 2.5 that ships by default.

Example with Python 2.5 as interpreter:

derek@interpol:~$ dog
The program 'dog' is currently not installed. You can install it by typing:
sudo apt-get install dog
-bash: dog: command not found

--
Example with Python 2.4 as interpreter:

derek@interpol:~$ dog
  File "/usr/lib/command-not-found", line 40
    finally:
          ^
SyntaxError: invalid syntax

--
I'm switching python versions by using the following command as root:
 unlink /usr/bin/python && ln -s /usr/bin/python2.4 /usr/bin/python

Colin Watson (cjwatson)
Changed in command-not-found:
assignee: nobody → kamion
status: New → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package command-not-found - 0.2.25ubuntu2

---------------
command-not-found (0.2.25ubuntu2) intrepid; urgency=low

  [ Era Eriksson ]
  * Print where-to-find-command, incorrect-PATH, and crash-guard messages to
    stderr rather than stdout (LP: #212723).

  [ Colin Watson ]
  * Fix various crash bugs in the crash handler (LP: #269821).
  * Adjust crash handler syntax to be friendly to Python 2.4 (LP: #234540).

 -- Colin Watson <email address hidden> Wed, 15 Oct 2008 13:27:20 +0100

Changed in command-not-found:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.