Skip to main content

zhpy is python on Chinese, which good for Taiwan and China beginners to learn python in their native language.

zhpy is a lightweight python module and a source convertor, which provides a command line tool to translate python code. The python code written by traditional and simplified chinese would be translated to nature python code (english).

zhpy use pyparsing module to detect chinese keywords, class name, methods, arguments, v ariables and translate them back to python.

It’s possible for developers to port zhpy to python on korean or python on japenese.

Check examples here.

Install zhpy

You could use easy_install command to install zhpy:

$ easy_install zhpy

or check instructions for detail.

Usage

You could use ‘zhpy’ command instead of “python” in command line to execute source code mixed in Chinese and English.:

$ zhpy hello.py
hello, world!

You could assign a file name to export the zhpy source to the normal python source (english):

$ zhpy hello.py nhello.py

Then run the exported file as normal python source:

$ python nhello.py
hello, world!

Programming

You could mix original english keywords and Chinese keywords in your zhpy source.

Reserved keywords are listed here

Release files for zhpy 0.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for zhpy 0.3
File Size Uploaded
zhpy-0.3.zip 16.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for zhpy 0.3
File Interpreter ABI Platform
zhpy-0.3-py2.5.egg Legacy Egg format - - Details

Total release size: 27.2 kB

Release files / zhpy-0.3.zip

Download URL zhpy-0.3.zip
Size 16.7 kB
Tags Source
SHA-256 checksum
How to use checksums
fb60ddd14fe94b06870c1518761d3628f80a025c17b891212f5c0447e652fa9f
BLAKE2b-256 checksum
How to use checksums
46547850bca8fd7ad74bb425d4f862a1baaca88c4c59c4f8236e72009bdbf29f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / zhpy-0.3-py2.5.egg

Download URL zhpy-0.3-py2.5.egg
Size 10.5 kB
Tags Egg
SHA-256 checksum
How to use checksums
d161ff66f68047acd03923e1410dc93bc98c428d89f40f1154584a893be92bb7
BLAKE2b-256 checksum
How to use checksums
ac45a3021831f0245220339c7028b0ba7a4f71272dac0eed3aabcad31f47eb59
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

1.7.4

2 release files

1.7.3

2 release files

1.7.2

2 release files

1.7.1

2 release files

1.7

2 release files

1.6

2 release files

1.5.2

2 release files

1.5.1

2 release files

1.5

2 release files

1.4

2 release files

1.3

2 release files

1.2

2 release files

1.1.1

2 release files

1.1

2 release files

1.0

2 release files

0.9.4

2 release files

0.9.3

2 release files

0.9.2

2 release files

0.9.1

2 release files

0.9

2 release files

0.8.1

2 release files

0.8

2 release files

0.7

2 release files

0.6

2 release files

0.5

2 release files

0.4

2 release files

This release

0.3 This release

2 release files

0.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page