Name | flake8-nested-fstrings JSON |
Version |
1.0.1
JSON |
| download |
home_page | |
Summary | flake8 plugin which forbids nesting f-strings inside other f-strings. |
upload_time | 2023-10-12 21:15:27 |
maintainer | |
docs_url | None |
author | |
requires_python | >=3.12 |
license | MIT License Copyright (c) 2023 Ferran Jovell Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. |
keywords |
flake8
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
[![build status](https://github.com/mrswats/flake8-nested-fstrings/actions/workflows/main.yml/badge.svg)](https://github.com/mrswats/flake8-nested-fstrings/actions/workflows/main.yml)
# flake8-nested-fstrings
flake8 plugin which forbids nesting f-strings inside other f-strings.
:warning: Python 3.12+
## Installation
```
pip install flake8-nested-fstrings
```
## Rationale
Quoting the zen of python:
```
Flat is better than nested.
```
## Codes
| Code | Description |
| ------ | ---------------------- |
| NFS001 | do not nest f-strings. |
## as a pre-commit hook
See [pre-commit](https://github.com/pre-commit/pre-commit) for instructions
Sample `.pre-commit-config.yaml`:
```yaml
- repo: https://github.com/pycqa/flake8
rev: 3.8.4
hooks:
- id: flake8
additional_dependencies: [flake8-nested-fstrings==1.0.0]
```
Raw data
{
"_id": null,
"home_page": "",
"name": "flake8-nested-fstrings",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.12",
"maintainer_email": "",
"keywords": "flake8",
"author": "",
"author_email": "Ferran Jovell <ferran.jovell+gh@gmail.com>",
"download_url": "",
"platform": null,
"description": "[![build status](https://github.com/mrswats/flake8-nested-fstrings/actions/workflows/main.yml/badge.svg)](https://github.com/mrswats/flake8-nested-fstrings/actions/workflows/main.yml)\n\n# flake8-nested-fstrings\n\nflake8 plugin which forbids nesting f-strings inside other f-strings.\n\n:warning: Python 3.12+\n\n## Installation\n\n```\npip install flake8-nested-fstrings\n```\n\n## Rationale\n\nQuoting the zen of python:\n\n```\nFlat is better than nested.\n\n```\n\n## Codes\n\n| Code | Description |\n| ------ | ---------------------- |\n| NFS001 | do not nest f-strings. |\n\n## as a pre-commit hook\n\nSee [pre-commit](https://github.com/pre-commit/pre-commit) for instructions\n\nSample `.pre-commit-config.yaml`:\n\n```yaml\n- repo: https://github.com/pycqa/flake8\n rev: 3.8.4\n hooks:\n - id: flake8\n additional_dependencies: [flake8-nested-fstrings==1.0.0]\n```\n",
"bugtrack_url": null,
"license": "MIT License Copyright (c) 2023 Ferran Jovell Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ",
"summary": "flake8 plugin which forbids nesting f-strings inside other f-strings.",
"version": "1.0.1",
"project_urls": null,
"split_keywords": [
"flake8"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "6187ab1a904b2e4fe615d7f0ce77240c8d7bbb5ce280876c3781b10215a1ee3a",
"md5": "f04c00a57aac8d62896f5778e8f48494",
"sha256": "2009e6aed3bc813422c4c5711f35c24b414f7fd6d2ba7c6116fed93794dd229a"
},
"downloads": -1,
"filename": "flake8_nested_fstrings-1.0.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "f04c00a57aac8d62896f5778e8f48494",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.12",
"size": 4129,
"upload_time": "2023-10-12T21:15:27",
"upload_time_iso_8601": "2023-10-12T21:15:27.851550Z",
"url": "https://files.pythonhosted.org/packages/61/87/ab1a904b2e4fe615d7f0ce77240c8d7bbb5ce280876c3781b10215a1ee3a/flake8_nested_fstrings-1.0.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-10-12 21:15:27",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "flake8-nested-fstrings"
}