{ "info": { "author": "Liam Curry", "author_email": "liam@curry.name", "bugtrack_url": null, "classifiers": [ "Environment :: Console", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.6", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.3", "Topic :: Software Development", "Topic :: Utilities" ], "description": "========\npy3kwarn\n========\n\n.. image:: https://travis-ci.org/liamcurry/py3kwarn.png?branch=master\n :target: https://travis-ci.org/liamcurry/py3kwarn\n :alt: Build status\n\n.. image:: https://coveralls.io/repos/liamcurry/py3kwarn/badge.png?branch=master\n :target: https://coveralls.io/r/liamcurry/py3kwarn\n :alt: Test coverage status\n\npy3kwarn detects code that is not Python 3 compatible. It provides\nflake8-style warning messages.\n\nSee also:\n\n- The lib2to3_ documentation for information on warning messages.\n- `What's new in Python 3.0`_\n\n*Pull requests are welcome!*\n\nInstallation\n------------\n\n**Supports Python 2.6, 2.7, and 3.3+**\n\n::\n\n $ pip install py3kwarn\n\n...or to install from the git repository::\n\n $ pip install -e git+git://github.com/liamcurry/py3kwarn.git#egg=py3kwarn\n\nUsage with vim\n--------------\n\nYou can use py3kwarn `with syntastic`_. If you want to use py3kwarn with\nanother syntax checker (like flake8), then you will have to add this to your\nvim config::\n\n let g:syntastic_python_checkers=['flake8', 'py3kwarn']\n\nUsage from the command line\n---------------------------\n\n::\n\n $ py3kwarn example.py\n example.py:2:1: PY3K (FixApply) apply(hello, args, kwargs) -> hello(*args, **kwargs)\n example.py:5:1: PY3K (FixBasestring) basestring -> str\n example.py:15:1: PY3K (FixDict) d.iteritems(); -> iter(d.items());\n example.py:16:1: PY3K (FixDict) d.viewvalues(); -> d.values();\n example.py:19:1: PY3K (FixExcept) try:import asdf;except E, T:pass; -> try:import asdf;except E as T:pass;\n example.py:25:1: PY3K (FixExec) exec code in ns1, ns2; -> exec(code, ns1, ns2);\n example.py:28:1: PY3K (FixExecfile) execfile('test.py') -> exec(compile(open('test.py').read(), 'test.py', 'exec'))\n example.py:31:1: PY3K (FixFilter) filter(lambda x: x, [1, 2, 3]) -> [x for x in [1, 2, 3] if x]\n example.py:36:1: PY3K (FixFuncattrs) test.func_name; -> test.__name__;\n example.py:37:1: PY3K (FixFuncattrs) test.func_closure; -> test.__closure__;\n example.py:38:1: PY3K (FixFuncattrs) test.func_dict; -> test.__dict__;\n example.py:44:1: PY3K (FixHasKey) d.has_key('foobar') -> 'foobar' in d\n example.py:56:1: PY3K (FixInput) input('FixInput') -> eval(input('FixInput'))\n example.py:66:1: PY3K (FixItertoolsImports) from itertools import imap -> \n example.py:67:1: PY3K (FixItertoolsImports) from itertools import ifilter; -> \n example.py:68:1: PY3K (FixItertoolsImports) from itertools import izip; -> \n example.py:69:1: PY3K (FixItertoolsImports) from itertools import ifilterfalse; -> from itertools import filterfalse;\n example.py:62:1: PY3K (FixLong) long; -> int;\n example.py:75:1: PY3K (FixLong) long -> int\n example.py:50:1: PY3K (FixImports) import StringIO -> import io\n example.py:51:1: PY3K (FixImports) import cStringIO; -> import io;\n example.py:52:1: PY3K (FixImports) import cPickle; -> import pickle;\n example.py:53:1: PY3K (FixImports) import __builtin__; -> import builtins;\n example.py:62:1: PY3K (FixIsinstance) isinstance(x, (int, int)) -> isinstance(x, int)\n example.py:63:1: PY3K (FixIsinstance) isinstance(x, (int, int)); -> isinstance(x, int);\n example.py:11:1: PY3K (FixCallable) callable('hello') -> isinstance('hello', collections.Callable)\n example.py:59:1: PY3K (FixIntern) intern(s) -> sys.intern(s)\n\nModifying code automatically\n----------------------------\n\nProblems can be fixed via ``py3kwarn2to3``::\n\n $ py3kwarn2to3 --write example.py\n\nTesting\n-------\n\nTesting can be done with ``make test``. py3kwarn also supports `tox`_. This\nenables quickly testing changes in many versions of python. Take a look at the\n``tox.ini`` file for more details.\n\nContributing\n------------\n\nTo contribute, fork the repo and clone to your local machine.\n\nCreate a virtual environment and ::\n\n pip install -r requirements_dev.txt\n\nThen just make a pull request with the issues you've fixed!\n\nTODO\n----\n\n- Friendlier messages.\n- `A flake8 extension`_.\n- Flags to ignore certain errors\n- Make it faster. Right now it is quite slow compared to other syntax checkers.\n Major refactoring may be necessary.\n\n\n.. _What's new in Python 3.0: http://docs.python.org/3/whatsnew/3.0.html\n.. _with syntastic: https://github.com/scrooloose/syntastic/blob/master/syntax_checkers/python/py3kwarn.vim\n.. _A flake8 extension: http://flake8.readthedocs.org/en/latest/extensions.html\n.. _lib2to3: http://docs.python.org/2.6/library/2to3.html#fixers\n.. _tox: http://tox.readthedocs.org/en/latest/", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/liamcurry/py3kwarn", "keywords": null, "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "py3kwarn", "package_url": "https://pypi.org/project/py3kwarn/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/py3kwarn/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/liamcurry/py3kwarn" }, "release_url": "https://pypi.org/project/py3kwarn/0.4.4/", "requires_dist": null, "requires_python": null, "summary": "Detects code that is not Python 3 compatible.", "version": "0.4.4" }, "last_serial": 881462, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "8e6dafbd2602986368cb8c30d0d6c3be", "sha256": "35af445371bde903a71d58273c8f1dc252e096fbc729ae21f1571de088006540" }, "downloads": -1, "filename": "py3kwarn-0.1.macosx-10.8-intel.exe", "has_sig": false, "md5_digest": "8e6dafbd2602986368cb8c30d0d6c3be", "packagetype": "bdist_wininst", "python_version": "any", "requires_python": null, "size": 67786, "upload_time": "2013-04-16T21:13:42", "url": "https://files.pythonhosted.org/packages/cd/35/0d57ca1a6238a1438aa2c841fd2ec04e7013377dd96166d7e7c426d743d8/py3kwarn-0.1.macosx-10.8-intel.exe" }, { "comment_text": "", "digests": { "md5": "fa7c33ff3bf8c3b8c57140448e64c37c", "sha256": "87dd072358cc51558b5ed222651a3f05b361f9ca65036ffabc3a54fe05dea8d1" }, "downloads": -1, "filename": "py3kwarn-0.1.tar.gz", "has_sig": false, "md5_digest": "fa7c33ff3bf8c3b8c57140448e64c37c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3928, "upload_time": "2013-04-16T21:13:34", "url": "https://files.pythonhosted.org/packages/06/c1/4b963a1a4e8cbcd898f991d25e9ea3cf7a9ef80231ae75768042155a08f2/py3kwarn-0.1.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "78310008989c8b9a826d48582b2cf82e", "sha256": "e5a5519b77cc5007cfbfcf7b0291d4cd57b71aa129a047ea86bce42a4b0b02aa" }, "downloads": -1, "filename": "py3kwarn-0.1.1.macosx-10.8-intel.exe", "has_sig": false, "md5_digest": "78310008989c8b9a826d48582b2cf82e", "packagetype": "bdist_wininst", "python_version": "any", "requires_python": null, "size": 68445, "upload_time": "2013-04-16T22:28:17", "url": "https://files.pythonhosted.org/packages/87/6e/17ba11ae499e9f37eea6f76a1748628bc5730c587afb4cd681408cf8376b/py3kwarn-0.1.1.macosx-10.8-intel.exe" }, { "comment_text": "", "digests": { "md5": "05fa91e8cb39ee518e7e5f4deffce55f", "sha256": "e64acdaba07e0246af49fed4c416b6ab83abbd62053043e12ac4dc7221238f3d" }, "downloads": -1, "filename": "py3kwarn-0.1.1.tar.gz", "has_sig": false, "md5_digest": "05fa91e8cb39ee518e7e5f4deffce55f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4033, "upload_time": "2013-04-16T22:28:13", "url": "https://files.pythonhosted.org/packages/98/72/dd906488a91b0d597485cbfc8620c5066428919f1b03725c34f9626963a7/py3kwarn-0.1.1.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "8ca9c539ac1840067814b516f66862e5", "sha256": "1b0ce49557d55c7daea1fe008df140d09d63da3989d15bf451bd707539ebacde" }, "downloads": -1, "filename": "py3kwarn-0.1.2.tar.gz", "has_sig": false, "md5_digest": "8ca9c539ac1840067814b516f66862e5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5108, "upload_time": "2013-04-16T23:47:28", "url": "https://files.pythonhosted.org/packages/40/7e/fdc017a957f4fc63d717b642fbed1b3568f9a134e99a43f5f05f633550b2/py3kwarn-0.1.2.tar.gz" } ], "0.1.3": [ { "comment_text": "", "digests": { "md5": "94ef40be29081cb41381f94e2d70b701", "sha256": "e636d649ff668d09b9efecc1a49feb1dde218f08d4f819ef83874efbdf46b2bc" }, "downloads": -1, "filename": "py3kwarn-0.1.3.tar.gz", "has_sig": false, "md5_digest": "94ef40be29081cb41381f94e2d70b701", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5096, "upload_time": "2013-04-17T00:04:11", "url": "https://files.pythonhosted.org/packages/f2/2e/cac7dc97cb124a262cf9e8c23473f5f2e4da3b532afde9c9e2cfd727b03e/py3kwarn-0.1.3.tar.gz" } ], "0.1.4": [ { "comment_text": "", "digests": { "md5": "1d76d8f630cad134556388b4bf61dd54", "sha256": "df5721cc3685ce5939149de121a2f1bc3fbea73bd3a0524d720614a348a52bf4" }, "downloads": -1, "filename": "py3kwarn-0.1.4.tar.gz", "has_sig": false, "md5_digest": "1d76d8f630cad134556388b4bf61dd54", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8073, "upload_time": "2013-04-17T16:38:52", "url": "https://files.pythonhosted.org/packages/f4/e8/e5ffaf3958274fb8a962b9ede98d96d1ef5b5d7f4f0a584801d7f7d5fd53/py3kwarn-0.1.4.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "bad56fd36e234b318f2b0264914bd709", "sha256": "c42d7697c659ef838007bad9397d35e03a717cd57b4163a37cac7596ae1e402e" }, "downloads": -1, "filename": "py3kwarn-0.2.0.tar.gz", "has_sig": false, "md5_digest": "bad56fd36e234b318f2b0264914bd709", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 89545, "upload_time": "2013-04-20T01:44:16", "url": "https://files.pythonhosted.org/packages/dc/f8/98e3fda07e301fb32686c33ec7d3d3ae27db4a4181e792ca2aacb4d48eaf/py3kwarn-0.2.0.tar.gz" } ], "0.2.3": [ { "comment_text": "", "digests": { "md5": "a78cb83a321c01f0ba3bfddc5ec3de8c", "sha256": "a92c1dfcd2cd5b29f960607eef5de9ca08cfbab02f17ab1e28933c68cc9eddc7" }, "downloads": -1, "filename": "py3kwarn-0.2.3.tar.gz", "has_sig": false, "md5_digest": "a78cb83a321c01f0ba3bfddc5ec3de8c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 89917, "upload_time": "2013-04-22T15:11:15", "url": "https://files.pythonhosted.org/packages/47/35/7e03588eb6d89ed22afa8049d87aca7df57488b6a1d3df161af25150c6d6/py3kwarn-0.2.3.tar.gz" } ], "0.3": [ { "comment_text": "", "digests": { "md5": "6790ff0ad8c4ed6cd3e6554accf791a3", "sha256": "f8b181996eafc81f5cd236570ff5f74280f7944120c02a4e56ab62f17ac5a38e" }, "downloads": -1, "filename": "py3kwarn-0.3.tar.gz", "has_sig": false, "md5_digest": "6790ff0ad8c4ed6cd3e6554accf791a3", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 83129, "upload_time": "2013-05-05T16:58:37", "url": "https://files.pythonhosted.org/packages/e2/4a/32fb0cbb04a8f5c29a71de89158432a57ebcf726502cdffe1b91b660169a/py3kwarn-0.3.tar.gz" } ], "0.4": [ { "comment_text": "", "digests": { "md5": "4f5992ac2bb2392986b6cf91326f41c5", "sha256": "c418abfe7a01049de313235112ba86f2aae6c014e39d6875146f7c44673ee8e6" }, "downloads": -1, "filename": "py3kwarn-0.4.tar.gz", "has_sig": false, "md5_digest": "4f5992ac2bb2392986b6cf91326f41c5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 92226, "upload_time": "2013-05-12T15:35:10", "url": "https://files.pythonhosted.org/packages/a9/ef/1d90f60791b3494b45a52052739df936ca42bfab7cf2d81bcaa3cbfaad15/py3kwarn-0.4.tar.gz" } ], "0.4.1": [ { "comment_text": "", "digests": { "md5": "3969bb6f4629c1c03e62958bda5f0489", "sha256": "6d24cea4d5c8ae5391f11c390889cc9634d71c3fa7ffc6f1c3f45b7bc7732fc7" }, "downloads": -1, "filename": "py3kwarn-0.4.1.tar.gz", "has_sig": false, "md5_digest": "3969bb6f4629c1c03e62958bda5f0489", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 92402, "upload_time": "2013-05-19T15:26:38", "url": "https://files.pythonhosted.org/packages/a6/fc/3aeae2350e4e6c94d78742f4b7ab3afd99ccc1841ee573ada398b4a194ce/py3kwarn-0.4.1.tar.gz" } ], "0.4.2": [ { "comment_text": "", "digests": { "md5": "84e671938a5ef017e62afc633982e6ec", "sha256": "5444f1930bfe87b541962879f5d6eb03d47417ce599a8ce5225ee7d75860a364" }, "downloads": -1, "filename": "py3kwarn-0.4.2.tar.gz", "has_sig": false, "md5_digest": "84e671938a5ef017e62afc633982e6ec", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 93076, "upload_time": "2013-05-25T15:07:00", "url": "https://files.pythonhosted.org/packages/46/6b/7900ffc354eef586eb2f90e6188a39da6f14ada176c9764725d78e2d01a4/py3kwarn-0.4.2.tar.gz" } ], "0.4.3": [ { "comment_text": "", "digests": { "md5": "039ad426926d45091bae705b02844753", "sha256": "625f4f706492b901788ab5450756f6f87ae0a1731f22eb2e119b9c11e3adf0a3" }, "downloads": -1, "filename": "py3kwarn-0.4.3.tar.gz", "has_sig": false, "md5_digest": "039ad426926d45091bae705b02844753", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 93472, "upload_time": "2013-06-29T01:18:54", "url": "https://files.pythonhosted.org/packages/68/0b/a7d9094ca14bad2658f1f38931d3209cb292216730388b223e952ada4d72/py3kwarn-0.4.3.tar.gz" } ], "0.4.4": [ { "comment_text": "", "digests": { "md5": "d5f858fd0c7426faacb00fb0df3e4df4", "sha256": "d4da108f5fecc6db8e7dc2d9365fedb6e7d886577b583ed477c52a92d9250d33" }, "downloads": -1, "filename": "py3kwarn-0.4.4.tar.gz", "has_sig": false, "md5_digest": "d5f858fd0c7426faacb00fb0df3e4df4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 93335, "upload_time": "2013-10-04T21:19:58", "url": "https://files.pythonhosted.org/packages/83/0e/4195e8d0f761b5efe1e1349d988fb73d73707ff5464568aba298fdc1bf6f/py3kwarn-0.4.4.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "d5f858fd0c7426faacb00fb0df3e4df4", "sha256": "d4da108f5fecc6db8e7dc2d9365fedb6e7d886577b583ed477c52a92d9250d33" }, "downloads": -1, "filename": "py3kwarn-0.4.4.tar.gz", "has_sig": false, "md5_digest": "d5f858fd0c7426faacb00fb0df3e4df4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 93335, "upload_time": "2013-10-04T21:19:58", "url": "https://files.pythonhosted.org/packages/83/0e/4195e8d0f761b5efe1e1349d988fb73d73707ff5464568aba298fdc1bf6f/py3kwarn-0.4.4.tar.gz" } ] }