Skip to content

WIP: Address python linter complaints #4488

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

Draft
wants to merge 72 commits into
base: devel
Choose a base branch
from

Conversation

ThalesBarretto
Copy link
Contributor

@ThalesBarretto ThalesBarretto commented Feb 26, 2025

Currently the python linter logs test mostly ok, but they are filled with warnings.
IMHO that's a lot of noise, and almost all the fixes are really trivial.

To the record we:
Reference : 1736 flake8 issues , pylint rating 6.12/10.
Last build: 232 flake8 issues , pylint rating 6.81/10.

This series addresses the TRIVIAL linter warnings.

@gluster-ant
Copy link
Collaborator

Can one of the admins verify this patch?

1 similar comment
@gluster-ant
Copy link
Collaborator

Can one of the admins verify this patch?

@ThalesBarretto ThalesBarretto force-pushed the thales_address_python_linter_complaints branch 4 times, most recently from 217604b to a684b73 Compare February 27, 2025 04:35
@ThalesBarretto ThalesBarretto changed the title Address python linter complaints with huge warning logs. Address python linter complaints Feb 27, 2025
@ThalesBarretto
Copy link
Contributor Author

/run regression

        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
…ibgfchangelog.py

        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
…hanges.py

        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
@ThalesBarretto ThalesBarretto force-pushed the thales_address_python_linter_complaints branch from a684b73 to d456543 Compare February 28, 2025 19:09
Copy link
Contributor Author

@ThalesBarretto ThalesBarretto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do not change strings that generate code

import sys

from generator import ops, fop_subs, cbk_subs, generate

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do not change the template strings

@ThalesBarretto ThalesBarretto force-pushed the thales_address_python_linter_complaints branch 2 times, most recently from 8a2389d to 8815c0e Compare March 4, 2025 01:47
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
@ThalesBarretto ThalesBarretto force-pushed the thales_address_python_linter_complaints branch from 8815c0e to c2bd603 Compare March 4, 2025 03:29
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
…er.py

        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

        This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
	This series aim to reduce the python linter build logs.

	This commit silences most of the python linter complaints
without any functional changes. The changes include mostly formatting
and missing obvious docstrings. We left out dependency and exception
handling complaints on purpose to be addressed separately.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
@ThalesBarretto ThalesBarretto force-pushed the thales_address_python_linter_complaints branch from c2bd603 to f30e199 Compare March 5, 2025 13:45
        This series aim to reduce the python linter build logs.

	This commit changes to "raw" strings for regex operations.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

	This commit changes to "raw" strings for regex operations.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

	This commit changes to "raw" strings for regex operations.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

	This commit changes to "raw" strings for regex operations.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

	This commit changes to "raw" strings for regex operations.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

	This commit changes to "raw" strings for regex operations.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

	This commit changes to "raw" strings for regex operations.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

	This commit changes to "raw" strings for regex operations.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

	This commit changes unassigned strings to comments.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

	This commit changes a syntax error for checking when checking
for membership with "for not x in group" to "for x not in group".

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

	Changes a comparison to literal value done with "is" to "==".

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
        This series aim to reduce the python linter build logs.

	This commit changes unassigned strings to comments.

Signed-off-by: Thales Antunes de Oliveira Barretto <[email protected]>
@ThalesBarretto ThalesBarretto changed the title Address python linter complaints WIP: Address python linter complaints Mar 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants