Skip to content

Merge changes from sandrobonazzola's fork - #395

Closed
psss wants to merge 147 commits into
mainfrom
fork
Closed

Merge changes from sandrobonazzola's fork#395
psss wants to merge 147 commits into
mainfrom
fork

Conversation

@psss

@psss psss commented May 17, 2025

Copy link
Copy Markdown
Owner

Notable changes:

  • Collect stats in parallel
  • Handle Jira API ratelimit
  • Fixed several deprecation warning and pylint reported issues
  • Improved stability and error handling
  • Improved test coverage

Original pull request from @sandrobonazzola: #390

Adding markdown format output to koji plugin.
In order to provide a link to the build, `weburl` option is required,
pointing to the koji web interface.
It's now possible to use token authentication for connecting to
Confluence. Page list is now also available in markdown format.

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Recently Red Hat bugzilla SSL certificate is failing verification.
In order to allow querying bugzilla while this issue is getting fixed,
allowing to skip SSL certificate validation.

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixing pylint warnings:
W1201: Use lazy % formatting in logging functions (logging-not-lazy)
W1202: Use lazy % or % formatting in logging functions (logging-format-interpolation)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixed:
W0707: Consider explicitly re-raising using ... (raise-missing-from)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixing:
R0205: Class inherits from object,
can be safely removed from bases in python3
(useless-object-inheritance)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixing W0622: Redefining built-in (redefined-builtin)
While doing it, removing the unused function utils.ascii
which was overriding the ascii built-in as the only place where it was
used was its test unit.

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
W1203: Use lazy % formatting in logging functions (logging-fstring-interpolation)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
W0107: Unnecessary pass statement (unnecessary-pass)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
W1406: The u prefix for strings is no longer necessary
in Python >=3.0 (redundant-u-string-prefix)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
W0611: Unused pformat imported from pprint as pretty (unused-import)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
W0104: Statement seems to have no effect (pointless-statement)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
DeprecationWarning: 'maxsplit' is passed as positional argument

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixing:
W3101: Missing timeout argument for method 'requests.get'
can cause your program to hang indefinitely (missing-timeout)

by adding an optional timeout config to the plugins using that method,
defaulting to 60 seconds if not set.

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Use proper os.path.join dealing with paths and use f-string to make more
understandable the desired strings.

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
R1724: Unnecessary "else" after "continue", remove the "else"
and de-indent the code inside it (no-else-continue)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
R1704: Redefining argument with the local name ... (redefined-argument-from-local)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
R1734: Consider using [] instead of list() (use-list-literal)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
W0237: Parameter '...' has been renamed to '...' in overriding '...' method (arguments-renamed)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
W1514: Using open without explicitly specifying an encoding (unspecified-encoding)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes #298

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
R1732: Consider using 'with' for resource-allocating operations (consider-using-with)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixers:
W0102: Dangerous default value [] as argument (dangerous-default-value)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
R1705 - Unnecessary "..." after "return", ...

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
W0612: Unused variable '...' (unused-variable)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Fixes:
W0718: Catching too general exception ... (broad-exception-caught)

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Allow to pass pylint deps checks.
Avoid using unmaintained github action.

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Need to investigate why test_cli is failing on this specific plugin
while the tests of the plugin themselves are passing

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
while trying to figure out why it doesn't work in GitHub actions environment

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
making it build on el9 too.

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Commit db48ed7 allowed to continue
execution of the stats collection even on a plugin failure.
Adjusting tests to match the new behaviour.

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
github hits ratelimit which makes tmt test failing due to timeout.
Switching to koji plugin, not suffering from rate limiting.

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
- Added timeout support
- Added rate limit handling
- Reduced differences with jira plugin as preparation to refactoring

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Added hyperkitty and public_inbox plugins to the docs.

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
The query for github requesting to exclude an organization was badly
encoded.

Signed-off-by: Sandro Bonazzola <sbonazzo@redhat.com>
Comment thread tests/test_utils.py Fixed
@psss psss added this to the 0.22 milestone May 17, 2025
@psss psss self-assigned this May 17, 2025

@psss psss left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

@sandrobonazzola, thanks again! Looks great! Found just one bug in the zammad plugin, plus added just a couple minor suggestions.

Comment thread did/utils.py Outdated
Comment thread did/plugins/zammad.py Outdated
Comment thread tests/plugins/test_hyperkitty.py Outdated
Comment thread tests/plugins/test_git.py Outdated
Comment thread did/plugins/confluence.py Outdated
@sandrobonazzola

Copy link
Copy Markdown
Collaborator

Accepted all the suggestions

@psss

psss commented May 19, 2025

Copy link
Copy Markdown
Owner Author

Merged in #390.

@psss psss closed this May 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants