Welcome, guest | Sign In | My Account | Store | Cart

Notice! PyPM is being replaced with the ActiveState Platform, which enhances PyPM’s build and deploy capabilities. Create your free Platform account to download ActivePython or customize Python with the packages you require and get automatic updates.

pypm install zhpy

How to install zhpy

  1. Download and install ActivePython
  2. Open Command Prompt
  3. Type pypm install zhpy
 Python 2.7Python 3.2Python 3.3
Windows (32-bit) Available View build log
Windows (64-bit) Available View build log
Mac OS X (10.5+) Available View build log
Linux (32-bit) Available View build log
Linux (64-bit) Available View build log
MIT <http://www.opensource.org/licenses/mit-licens
Lastest release
version on Jan 5th, 2011

System Message: WARNING/2 (<string>, line 2)

Explicit markup ends without a blank line; unexpected unindent.


"If it walks like a duck and quacks like a duck, I would call it a duck."

Zhpy on python is good for Taiwan and China beginners to learn python in our native language (Currently support Traditional and Simplified chinese).

Zhpy acts like python and play like python, you (chinese users) could use it as python to educate yourself the program skills plus with your native language.

Check examples here.

Play Zhpy Online

Zhpy has online version (with limited feature) running with google app engine!

Play locally

To play zhpy locally, you even don't need to install it.

All you need to do is follow the 3 steps guide:

  1. Download the source pack (the zip file)

  2. Extract the pack with zip tool. Enter the folder

  3. Run:

    System Message: WARNING/2 (<string>, line 40)

    Literal block expected; none found.

$ python interpreter.py

Then you got the usable zhpy interpreter!


If you'd like to play zhpy with full features, you should install zhpy.

You could use easy_install command to install or upgrade zhpy:

$ easy_install -U zhpy

or check instructions for detail.


You could use zhpy interpreter to test zhpy:

$ zhpy

System Message: ERROR/3 (<string>, line 65)

Inconsistent literal block quoting.

zhpy [version] in [platform] on top of Python [py_version] >>> print 'hello in chinese' hello in chinese

Browse project homepage to get examples in chinese.

check the BasicUsage for detail.

Programming Guide

You could freely view the C.C. licensed book "A Byte of python (Zhpy)" on zhpy website, which contained zhpy example codes as well.

There's the API document available in zhpy download list, too.

PS: The book is based on "A Byte of Python".

What is Zhpy

Zhpy is the full feature python language with fully tested chinese keywords, variables, and parameters support. Zhpy is INDEPENDENT on python version(2.4, 2.5....), bundle with command line tool, interpreter, bi-directional zhpy <-> python code translation, chinese shell script capability, in-place ini reference feature for keyword reuse, and great document (the book Byte of Python with chinese examples).

The core of zhpy is a lightweight python module and a chinese source convertor based on python, which provides interpreter and command line tool to translate zhpy code to python.

See http://www.flickr.com/photos/gasolin/2064120327

You could invoke interpreter with 'zhpy' command instead of "python" in command line to execute source code wrote in either Chinese or English. The zhpy interpreter also support autocomplete function to save your typing.

Zhpy provide a method 'zh_exec' that allow you to embed chinese script in python; Zhpy could be used as the chinese shell script as well.

The zhpy code written in traditional and simplified chinese could be translated and converted to natual python code. Thus it could be execute as nature python code and be used in normal python programs.

Bidirectional python-zhpy translation is possible. Normal python programs could be translated to traditional(.twpy) or simplified(.cnpy) chinese zhpy source via 'zhpy' command line tool.

The framework is not hard to extend to another languages such as japenese or korean.

Change Log

You could view the ChangeLog to see what's new in these version.

Subscribe to package updates

Last updated Jan 5th, 2011

Download Stats

Last month:1

What does the lock icon mean?

Builds marked with a lock icon are only available via PyPM to users with a current ActivePython Business Edition subscription.

Need custom builds or support?

ActivePython Enterprise Edition guarantees priority access to technical support, indemnification, expert consulting and quality-assured language builds.

Plan on re-distributing ActivePython?

Get re-distribution rights and eliminate legal risks with ActivePython OEM Edition.