Skip to main content

Flake8 plugin to forbid backslashes for line breaks

Project description

flake8-broken-line

wemake.services Build Status Coverage Python Version PyPI version

Do not break the line! 🚨

Installation

pip install flake8-broken-line

Code example

Things we check with this plugin:

# String line breaks, use `()` or `"""` instead:

some_string = 'first line\
second line'

# Use a single line, `()`, or new variables instead:

if 1 == 1 and \
    2 == 2:
    print('Do not do that!')

# Do not reimplement chaining:
some_object \
  .call_method() \
  .call_other() \
  .finalize()

Error codes

Error code Description
N400 Found backslash that is used for line braking

License

MIT.

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-broken-line-0.1.0.tar.gz (3.3 kB view details)

Uploaded Source

Built Distribution

flake8_broken_line-0.1.0-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file flake8-broken-line-0.1.0.tar.gz.

File metadata

  • Download URL: flake8-broken-line-0.1.0.tar.gz
  • Upload date:
  • Size: 3.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/0.11.2 CPython/3.6.5 Darwin/15.6.0

File hashes

Hashes for flake8-broken-line-0.1.0.tar.gz
Algorithm Hash digest
SHA256 84147d38a1562d011a8de0bb1de299a715f7dea1a7332bd6946db04a1e4c3ddd
MD5 ef5ab7f110bc19023961129740a30111
BLAKE2b-256 52575f1e1f7eeb6f2dc2a8f58e55ace0d455bf038f695383926c52b78019c89e

See more details on using hashes here.

File details

Details for the file flake8_broken_line-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for flake8_broken_line-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3eb823f48b4ec67735ebbe8e282319826c8e8be7dfc185c9e259228084c21de2
MD5 fbd0ded63be46040b329d39d8e5cbaf0
BLAKE2b-256 8277d4737c18a061c3f68751918494e98f5d3d3b24ef2c37c9e85be8bfddff53

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