An open API service indexing awesome lists of open source software.

https://github.com/5j9/flake8-invalid-escape-sequences

A plugin for flake8 that detects and reports invalid escape sequences
https://github.com/5j9/flake8-invalid-escape-sequences

escape-sequences flake8-plugin python python2 python3 quality-assurance

Last synced: 4 months ago
JSON representation

A plugin for flake8 that detects and reports invalid escape sequences

Awesome Lists containing this project

README

          

.. image:: https://travis-ci.org/5j9/flake8-invalid-escape-sequences.svg?branch=master
:target: https://travis-ci.org/5j9/flake8-invalid-escape-sequences

flake8-invalid-escape-sequences
-------------------------------
A plugin for flake8 (v3+) that detects and reports invalid escape sequences.

Note: This plugin is not required anymore if you've upgraded to ``pycodestyle 2.4.0`` (released Apr 10, 2018). ``pycodestyle`` now issues `W605 `_
warning for invalid escape sequences.

Introduction
------------
Invalid escape sequences `became deprecated in Python 3.6 `_ and will be a SyntaxError in the future.

This plugin finds those invalid sequences and reports them. Here is a sample output:

.. code-block:: bash

test_case.py:5:12: IES: invalid escape sequence \[

Installation
------------

.. code-block:: bash

pip install flake8-invalid-escape-sequences

Should work with all officially supported Python versions, including
Python 2.7.