Skip to content
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

Remove unnecessary whitespace in slice notation to align with PEP 8 and Black standards #5646

Closed
michaelwlin-osu opened this issue Nov 20, 2024 · 1 comment

Comments

@michaelwlin-osu
Copy link

File: flask/src/flask/cli.py
Line: 701

The return statement in the _path_is_ancestor function can be updated to improve readability and align with PEP 8 and Black formatting standards for slice notation. Currently, there is unnecessary whitespace around the colon (:) in the slice, which is inconsistent with these guidelines.

Current Code:
return os.path.join(path, other[len(path) :].lstrip(os.sep)) == other

Suggested Change:
Remove the unnecessary whitespace around the colon (:) in the slice notation to improve readability:
return os.path.join(path, other[len(path):].lstrip(os.sep)) == other

This change ensures compliance with PEP 8 and Black standards, contributing to cleaner and more consistent formatting across the codebase.

@ThiefMaster
Copy link
Member

Please don't open issues/PRs related to formatting.

@ThiefMaster ThiefMaster closed this as not planned Won't fix, can't repro, duplicate, stale Nov 20, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 5, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants