{"library":"pylint-flask","title":"pylint-flask","description":"pylint-flask is a Pylint plugin designed to improve static code analysis for Flask applications. It helps Pylint correctly interpret Flask-specific patterns, particularly addressing issues related to the `flask.ext` import style (which has since been deprecated in Flask itself) and other dynamic attributes in Flask extensions. The current version is 0.6, released in January 2019, indicating a maintenance phase with infrequent updates.","language":"python","status":"maintenance","last_verified":"Thu Apr 16","install":{"commands":["pip install pylint-flask"],"cli":null},"imports":["pylint --load-plugins pylint_flask your_module.py"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"# my_flask_app.py\nfrom flask import Flask\nfrom flask_wtf import CSRFProtect # Example: direct import for Flask-WTF\n\napp = Flask(__name__)\napp.config['SECRET_KEY'] = 'a-very-secret-key'\ncsrf = CSRFProtect(app)\n\n@app.route('/')\ndef index():\n    return 'Hello, Flask!'\n\n# To run pylint with the plugin:\n# pylint --load-plugins pylint_flask my_flask_app.py","lang":"python","description":"Install `pylint-flask` and then run Pylint, explicitly loading the plugin with the `--load-plugins` flag. This example shows a minimal Flask app and how to lint it. For Flask extensions, ensure you are using direct imports (e.g., `from flask_wtf import ...`) as the `flask.ext` pattern is deprecated in modern Flask versions.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}