Skip to main content

Checks for code usages that can be replaced with Plone API method calls.

Project description

https://travis-ci.org/gforcada/flake8-plone-api.svg?branch=master https://coveralls.io/repos/gforcada/flake8-plone-api/badge.svg?branch=master&service=github

Flake8 Plone API plugin

Checks for code usages that can be replaced with Plone API method calls.

See the current replacements (on DATA variable at the bottom) and propose new ones / fix existing ones.

Install

Install with pip:

$ pip install flake8-plone-api

Requirements

  • Python 2.7, 3.3, 3.4

  • flake8

License

GPL 2.0

Changelog

1.0 (2016-03-01)

  • Report which version of plone.api is needed to be able to apply each suggested replacement. [gforcada]

  • Add methods from plone.api 1.5. [gforcada]

0.6 (2015-10-06)

  • Instead of looking for catalog, look for .catalog, this should avoid some false positives [do3cc]

0.5 (2015-08-17)

  • Improve testing so that physical files are no longer needed. [gforcada]

  • Remove JSON data, use a regular python dictionary. [gforcada]

  • Fix old approach being a substring of another method (getSite and getSiteManager). Fixes https://github.com/gforcada/flake8-plone-api/issues/1 [gforcada]

  • Improve test coverage. [gforcada]

0.4 (2015-08-16)

  • Ignore XXX old usages, they are mostly a placeholder to keep the mapping easier. [gforcada]

0.3 (2015-08-16)

  • I give up, collapse everything into a single file, should be easy… [gforcada]

0.2.post1 (2015-08-16)

  • Yet another try. [gforcada]

0.2.post0 (2015-08-16)

  • Still not… [gforcada]

0.2 (2015-08-16)

  • All previous releases are broken, attempting to fix it (setuptools is playing with me). [gforcada]

0.1.post1 (2015-08-15)

  • Minor README enhancement. [gforcada]

0.1.post0 (2015-08-15)

  • Fix version number location. [gforcada]

0.1 (2015-08-15)

  • Initial release [gforcada]

  • Add buildout and other stuff. [gforcada]

  • Add a mapping.json to add Plone API method calls to old usages data [gforcada]

  • Add a mapping.py to convert mapping.json into a reverse mapping (to be used by the flake8 plugin). [gforcada]

  • Create the flake8 plugin per se that iterates over the files and searches for old usages (coming from mapping.py). [gforcada]

  • Add tests and badges for travis and coveralls [gforcada]

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

flake8-plone-api-1.0.tar.gz (16.6 kB view details)

Uploaded Source

File details

Details for the file flake8-plone-api-1.0.tar.gz.

File metadata

File hashes

Hashes for flake8-plone-api-1.0.tar.gz
Algorithm Hash digest
SHA256 7f1723d5b6c94386a72f6cc5ade6b9bee413d7b80ea7e605517fded760f7108d
MD5 d0678f19e3de71eba68f6f0969d6eee5
BLAKE2b-256 f7be1086752a38d0f638588d026a3db2c25af4938e6843965a54dea7d96c98c9

See more details on using hashes here.

Supported by

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