Flake8 plugin that forbids implicit string literal concatenations
Project description
flake8-no-implicit-concat
Flake8 plugin that forbids implicit string literal concatenations.
# NG
a = "abc" "def"
b = ["aaa",
"bbb"
"ccc"]
# OK
a = "abcdef"
b = ["aaa",
"bbb" +
"ccc"]
Installation
Install via pip:
pip install flake8-no-implicit-concat
Violation code
The plugin uses the prefix NIC
, short for No Implicit Concatenation.
Code | Description |
---|---|
NIC001 | Implicitly concatenated string literals |
Other Plugins & Linters
- flake8-implicit-str-concat
Flake8 plugin to encourage correct string literal concatenation.
There are cases where this plugin prefers implicit concatenation over
explicit
+
operator , so these two plugins cannot be used in combination. - wemake-python-styleguide
Set of strict flake8 rules with some other plugins as dependencies.
It implements
WPS326 Found implicit string concatenation
, which also checks implicit string concatenations, as one of the many rules it has. - pylint This linter has
implicit-str-concat
rule. By default it only looks for occurrences of implicit concatenations on the same line, but you can give the--check-str-concat-over-line-jumps=y
option for concatenations over multiple lines.
Development
Use Pipenv to run test locally:
pipenv install --dev
pipenv run check
License
This software is licensed under MIT license. See LICENSE
for details.
The code was derived from flake8-implicit-str-concat, which is developed by Dylan Turner and also licensed under MIT license.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for flake8-no-implicit-concat-0.1.5.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0453ffe74a05f6bb14c2aa96d7c2ee4b4d010bfbc0420c9bc5d671983da258f9 |
|
MD5 | e2dff85cf580d67026d979eaf40003b2 |
|
BLAKE2b-256 | 44d3b9dfb334abef9b131201b995c551014290d84179c30e5159b8cb1af9c0ac |
Close
Hashes for flake8_no_implicit_concat-0.1.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4f8b0f72a003cd046d545e3b5bb0ce61893e9fff1374826d17b38aae202452ed |
|
MD5 | ccb547a3451c6df7b2faad25ca12c3b7 |
|
BLAKE2b-256 | 86b9d88ad34a8cd60befac8a5b057d510c66fc59eeee699f54c6532948a15d0b |