-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Does not comply with E203 from pep8 #315
Comments
pep8 is wrong here. Quoting black's README: "This behaviour may raise E203 whitespace before ':' warnings in style guide enforcement tools like Flake8. Since E203 is not PEP 8 compliant, you should tell Flake8 to ignore these warnings." In general when using black it's safe to disable formatting-related errors in tools like flake8; black takes care of the styling minutiae for you. |
Thanks a lot, @JelleZijlstra ! |
Summary: Ignore sometimes incorrect flake8 warning about whitespace before ':' See psf/black#315 Differential Revision: D13565818 fbshipit-source-id: ce3ff158da2e4443e44f01c86dcbd889c9f5bcc1
Summary: Pull Request resolved: #15663 Ignore sometimes incorrect flake8 warning about whitespace before ':' See psf/black#315 Reviewed By: soumith Differential Revision: D13565818 fbshipit-source-id: 9d5ec2335899527ee71f4b505c00865a354e3bf0
* Format with Black. * Ignore E203. See psf/black#315
Complete teams and organisations, extend campaigns from tags into own objects Port teams, orgs and campaigns to APIv2 Cleaning up and debugging teams, orgs and campaigns backend fix revision for merge Handle non-null fields + Consistent table names CI fix: Update Image ID Black formatting Flake updates Flake fix Remove the default length Ignore E203 psf/black#315 Revert ignore flag on flake
… be resolved. Following the suggestion on this thread: psf/black#315
E203 isn't PEP8 compliant - see psf/black#315
E203 was removed per PEP 8, and line length was changed to 88. See psf/black#315
* E203: See psf/black#315 * W503: See psf/black#21
* E203: See psf/black#315 * W503: See psf/black#21
* E203: See psf/black#315 * W503: See psf/black#21
…modify.fix: ignore E203 in flake8, see psf/black#315 for details
…modify.fix: ignore E203 in flake8, see psf/black#315 for details
…modify.fix: ignore E203 in flake8, see psf/black#315 for details
…modify.fix: ignore E203 in flake8, see psf/black#315 for details
…modify.fix: ignore E203 in flake8, see psf/black#315 for details
…modify.fix: ignore E203 in flake8, see psf/black#315 for details
Flake8 was disagreeing with a formatting change black did. It turns out this is a known issue and it seems the recommended solution is to ignore this warning in flake8. See here for more details: psf/black#315 Signed-off-by: Martin Malina <mmalina@redhat.com>
* refactor(RHTAPBUGS-919): create components in batches By creating sbom components in Pyxis in batches of 5, the overall script runtime is reduced by around 47 % in my testing with an sbom with 113 components. The batch size is configurable, but currently set to 5. * fix: flake8 and black conflict Flake8 was disagreeing with a formatting change black did. It turns out this is a known issue and it seems the recommended solution is to ignore this warning in flake8. See here for more details: psf/black#315 Signed-off-by: Martin Malina <mmalina@redhat.com>
This conflicts with black. Black converts `arr[start:end]` to `arr[start : end]`. .flake8 fails because it expects that there are not spaces before `:` Here is the source psf/black#315
As explained in this issue[1], E203[2] is not PEP 8 compliant so it should be ignored when running flake8. Black is now being used in the codebase, and it takes care of the formatting. [1] psf/black#315 [2] https://www.flake8rules.com/rules/E203.html
As explained in this issue[1], E203[2] is not PEP 8 compliant so it should be ignored when running flake8. Black is now being used in the codebase, and it takes care of the formatting. [1] psf/black#315 [2] https://www.flake8rules.com/rules/E203.html
As explained in this issue[1], E203[2] is not PEP 8 compliant so it should be ignored when running flake8. Black is now being used in the codebase, and it takes care of the formatting. [1] psf/black#315 [2] https://www.flake8rules.com/rules/E203.html
* Set line length to 79 when calling black black uses pyproject.toml to store its configuration. Update the different projects in the monorepo to match line length of 79 when calling black. See black documentation[1] for more information. [1] https://black.readthedocs.io/en/stable/usage_and_configuration/the_basics.html#configuration-via-a-file * Update contributing guide to mention black * Add black GitHub Action * Ignore vendorized code when running black * Format all the codebase using black Command used: black . --line-length 79 --extend-exclude "/vendor/" * Ignore E203 (Whitespace before ':') As explained in this issue[1], E203[2] is not PEP 8 compliant so it should be ignored when running flake8. Black is now being used in the codebase, and it takes care of the formatting. [1] psf/black#315 [2] https://www.flake8rules.com/rules/E203.html * Ignore flake8 complaints for a few specific lines in the base provider Although Black is configured at 79 chars line length, it keeps a few lines to 80, 81 or 82 chars. Flake8 will complain about this, but we can ignore these.
* Set line length to 79 when calling black black uses pyproject.toml to store its configuration. Update the different projects in the monorepo to match line length of 79 when calling black. See black documentation[1] for more information. [1] https://black.readthedocs.io/en/stable/usage_and_configuration/the_basics.html#configuration-via-a-file * Update contributing guide to mention black * Add black GitHub Action * Ignore vendorized code when running black * Format all the codebase using black Command used: black . --line-length 79 --extend-exclude "/vendor/" * Ignore E203 (Whitespace before ':') As explained in this issue[1], E203[2] is not PEP 8 compliant so it should be ignored when running flake8. Black is now being used in the codebase, and it takes care of the formatting. [1] psf/black#315 [2] https://www.flake8rules.com/rules/E203.html * Ignore flake8 complaints for a few specific lines in the base provider Although Black is configured at 79 chars line length, it keeps a few lines to 80, 81 or 82 chars. Flake8 will complain about this, but we can ignore these.
* Add flake8 ignore for E203 (see psf/black#315) * Use batch size when adding documents to avoid embedding API overload * Move to python 3.12 * Use itertools.batched * Update .python-version * Fix SyntaxWarning * Print batch number correctly
* e203 does not coply with pep8 as per psf/black#315 * add basic setup * add 3 days of solutions * add pre commit validation and test * update python
Operating system:
Python version: 3.6
Black version: 18.6b1
Does also happen on master: yes
Create a file with
tup = nsamples, nalleless[i : i + size], i, size
and black won't correct the white spaces around
:
.The text was updated successfully, but these errors were encountered: