Skip to main content
Help us improve Python packaging – donate today!

Python byte-code to source-code converter

Project Description

uncompyle – A Python 2.7 byte-code decompiler
0.12 2012-1-23


‘uncompyle’ converts Python byte-code back into equivalent Python source. It accepts byte-code from Python version 2.7 only.

The generated source is very readable: docstrings, lists, tuples and hashes get pretty-printed.

‘uncompyle’ may also verify the equivalence of the generated source by by compiling it and comparing both byte-codes.

‘uncompyle’ is based on John Aycock’s generic small languages compiler ‘spark’ ( and his prior work on ‘decompyle’.

Additional note (3 July 2004, Ben Burton):

The original website from which this software was obtained is no longer available. It has now become a commercial decompilation service, with no software available for download.

Any developers seeking to make alterations or enhancements to this code should therefore consider these debian packages an appropriate starting point.


  • decompiles Python byte-code into equivalent Python source
  • decompiles byte-code from Python version 2.7
  • pretty-prints docstrings, hashes, lists and tuples
  • reads directly from .pyc/.pyo files, bulk-decompile whole directories
  • output may be written to file, a directory or to stdout
  • option for including byte-code disassembly into generated source

For a list of changes please refer to the ‘CHANGES’ file.


‘decompile’ requires Python 2.2 or later.


You may either create a RPM and install this, or install directly from the source distribution.

Creating RPMS:

python bdist_rpm

If you need to force the python interpreter to eg. pyton2:
python2 bdist_rpm –python=python2

Installation from the source distribution:

python install
To install to a user’s home-dir:
python install –home=<dir>
To install to another prefix (eg. /usr/local)
python install –prefix=/usr/local
If you need to force the python interpreter to eg. pyton2:
python2 install
For more information on ‘Installing Python Modules’ please refer to


uncompyler -h prints short usage uncompyler –help prints long usage

Known Bugs/Restrictions

Release history Release notifications

History Node


This version
History Node


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
uncompyle-1.1.tar.gz (348.3 kB) Copy SHA256 hash SHA256 Source None Jun 2, 2014

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page