Skip to main content

A small wrapper around lib2to3 that provide warnings messages for Python 3 incompatibilities

Project description

py3kwarn is a small wrapper around lib2to3 to help write Python3 compatible code. It provides flake8-style warning messages.

See the lib2to3 documentation for information on warning messages.

Pull requests are welcome!

Installation

Requires Python 2.7+

$ pip install py3kwarn

…or to install from the git repository:

$ git clone git://github.com/liamcurry/py3kwarn.git
$ cd py3kwarn
$ make install

Usage from the command line

$ py3kwarn [filename]

Usage with vim

To use with vim, check out my syntastic fork which adds py3kwarn as a syntax checker for python. If you want to use py3kwarn and syntastic with another syntax checker (like flake8), then you will have to add this to your vim config:

let g:syntastic_python_checkers=['flake8', 'py3kwarn']

TODO

  • An option for friendlier messages would be nice.

  • A flake8 extension.

  • Use argparse to add some smarter options.

  • Better docs

  • Make it work with Python 2.6

Project details


Download files

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

Source Distribution

py3kwarn-0.1.1.tar.gz (4.0 kB view details)

Uploaded Source

Built Distribution

py3kwarn-0.1.1.macosx-10.8-intel.exe (68.4 kB view details)

Uploaded Source

File details

Details for the file py3kwarn-0.1.1.tar.gz.

File metadata

  • Download URL: py3kwarn-0.1.1.tar.gz
  • Upload date:
  • Size: 4.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for py3kwarn-0.1.1.tar.gz
Algorithm Hash digest
SHA256 e64acdaba07e0246af49fed4c416b6ab83abbd62053043e12ac4dc7221238f3d
MD5 05fa91e8cb39ee518e7e5f4deffce55f
BLAKE2b-256 9872dd906488a91b0d597485cbfc8620c5066428919f1b03725c34f9626963a7

See more details on using hashes here.

File details

Details for the file py3kwarn-0.1.1.macosx-10.8-intel.exe.

File metadata

File hashes

Hashes for py3kwarn-0.1.1.macosx-10.8-intel.exe
Algorithm Hash digest
SHA256 e5a5519b77cc5007cfbfcf7b0291d4cd57b71aa129a047ea86bce42a4b0b02aa
MD5 78310008989c8b9a826d48582b2cf82e
BLAKE2b-256 876e17ba11ae499e9f37eea6f76a1748628bc5730c587afb4cd681408cf8376b

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page