136 Commits

Author SHA1 Message Date
João Walter Bruno Filho
23fe23b296 Make check_source ignore patchinfo using same rules as meta
Maintenance now uses patchinfo requests that were being declined by
the factory-auto bot.
2024-12-09 16:25:46 -03:00
729cf7d08e check_source: decline the request if target package exist in SLFO project 2024-09-10 18:56:10 +08:00
841a410733
Use f-strings everywhere 2024-08-02 11:06:50 +02:00
Dirk Müller
ef48709f90
Improve decline message (openSUSE/scm-staging#51) 2024-08-02 11:05:57 +02:00
706a18f577
check_source: fix crash AttributeError: 'CheckSource' object has no attribute 'review_message'
An old typo, that was introduced in an attempt to support scm synced PRs
2024-06-17 09:12:40 +02:00
Dirk Müller
730630f06f
Use f-strings where possible 2024-05-07 21:52:32 +02:00
Fabian Vogt
aa1b3d6062 check_source.py: Use correct function for getting maintainer of the devel pkg
"maintainers_get" is a bit weird and uses /search/owner and not the given prj.
2023-12-12 16:30:55 +01:00
Fabian Vogt
8e55eb3d0a check_source.py: Add review-team review on meta packages
All submissions must be reviewed before they can be accepted.
2023-09-20 08:57:53 +02:00
Fabian Vogt
2a369ec631 check_source.py: Don't skip various checks and reviews for non-spec packages
There was an early exit for packages which don't have a .spec file, but that
is too early and skipped important parts like running the source_validator
and download_files services and adding the review-team review.
2023-09-15 15:22:02 +02:00
ef84f01d1b
Revert temporary fixups, these are working now 2023-07-20 13:02:51 +02:00
e842fd26b1
Add some type hints 2023-06-29 11:27:23 +02:00
e7caf0b298
Cleanups for accepting scm-staging bot submissions
* Ignore .gitattributes in checkout
* Skip Name: check when it is a scm-staging bot submission
  (relies on build service API that is broken for git
  packages)
* Skip devel-group-maintainer check
2023-06-29 08:53:54 +02:00
90c7ad546c
check_source: fix condition checking for <scmsync> for git packaging 2023-06-27 20:52:34 +02:00
5470fa4fbe
Don't decline SRs from non-devel project for scmsync packages from the bot
We want to start transitioning to a git based development workflow. For the
first iteration, we would allow maintainers to opt-in by changing their package
in the devel project to use scmsync from src.opensuse.org/pool/${pkg_name} and
submit changes via pull requests on gitea. These pull requests will get
submitted directly by the scm-staging-bot to Factory from its home project as
submit requests.

Currently, such a submission would get auto-declined from the factory-auto
bot. With this commit, factory-auto will no longer decline such a submission
provided that the above conditions have been met.

Co-authored-by: Dirk Mueller <dmueller@suse.com>
2023-06-26 13:28:34 +02:00
Dirk Müller
fc7e7466ff
Fix handling of preinstall images
These have special name handling in `_preinstallimage`. The
package name has to be "preinstallimage-$name" where $name
is what is given in the _preinstallimage description
2023-03-03 13:37:48 +01:00
Fabian Vogt
014387e9a5 Port over more uses of Request.get_creator() 2023-01-31 12:34:10 +01:00
Stephan Kulow
f46742baef Don't hard code bash as interpreter for source_validator scripts 2022-10-25 12:19:54 +02:00
Stephan Kulow
7ba81bcfdb
Merge pull request #2848 from nilxam/backports_checker
check_source: expand check_source be able to handle Leap/Backports submission
2022-09-01 14:53:04 +02:00
7a088e7784 check_source: expand check_source be able to handle Leap/Backports submission
New features
* If package does exist in SLE, decline the submission
Note: release manager can override it by commenting on reviewbot and reopen the request
* Decline the submission if package does not exist in devel-baseproject and the
  source project does not exist in check-source-valid-source-origins attribute
* check_source adding a review-team group review if source project does not exist in check-source-valid-source-origins attribute
* If submitter is not maintainer adding an additional devel project review

New added attributes
* check-source-ensure-source-exist-in-baseproject: bool
* check-source-devel-baseproject: str
* check-source-allow-source-in-sle: bool
* check-source-sle-project: str
* check-source-allow-valid-source-origin: bool
* check-source-valid-source-origins: strlist
* check-source-add-devel-project-review: bool
2022-08-30 19:46:02 +08:00
b40d8c0053 Fix E275: missing whitespace around keywords 2022-08-18 11:05:55 +02:00
Stephan Kulow
e4cb06a692 Do not decline requests with download_files errors
The URLs might suffer from flaky networks, so just block the request
from accepted for now (and extend the review comment to make it
discoverable why factory-auto didn't approve)

Fixes #2666
2022-03-25 12:11:35 +01:00
Stephan Kulow
55c4081ec0 check_source: Allow a .changes line to mention 2 patches 2022-03-25 11:26:53 +01:00
Stephan Kulow
ae658fefe2 Move download URL check to check_source.py
And with that, check_source.pl is gone
2022-03-25 09:19:24 +01:00
Stephan Kulow
ed87520710 Ignore patches that are listed as sources
The patch live cycle does not apply to them
2022-03-25 07:39:17 +01:00
Stephan Kulow
c8531891a1 Move the 'patch in changes' check from check_source.pl to .py 2022-03-24 21:20:07 +01:00
Stephan Kulow
6931c44099 Run source_validator scripts from check_source.py directly 2022-03-24 17:42:52 +01:00
Stephan Kulow
88749aa5b4 Move license check from check_source.pl to .py 2022-03-24 17:42:52 +01:00
Stephan Kulow
b558e2617c Move changes check from check_source.pl to .py 2022-03-24 17:42:52 +01:00
Stephan Kulow
d1ddbc5831 Move spec file checks from check_source.pl to .py 2022-03-24 17:42:52 +01:00
Stephan Kulow
e7c7a4097b Add test for remote services in factory-auto
Can't test it atm, need to have miniobs updated first
2022-03-24 10:31:34 +01:00
Stephan Kulow
296b78f9ec Move check for generated files from check_source.pl to .py 2022-03-24 08:48:06 +01:00
Stephan Kulow
23af9a0b72 Move rpmlintrc checking from check_source.pl to .py 2022-03-24 08:39:20 +01:00
Stephan Kulow
3a497700f0 Remove diff preparations from check_source.pl
It's dead since #1073 but weren't removed with the actual diffing
2022-03-24 08:32:08 +01:00
Stephan Kulow
1e2565ce50 Move service check from check_source.pl to .py 2022-03-24 08:25:32 +01:00
Stephan Kulow
f414161a1e Remove unused repo_checker config entries 2022-03-24 08:05:34 +01:00
Stephan Kulow
76308e96aa Remove rpmlint check from check_source
Reverts #2153 and
Fixes #2192
2022-03-23 16:12:09 +01:00
Stephan Kulow
f86579642b Target E501 - Line too long
https://www.flake8rules.com/rules/E501.html - but 79 characters is a
joke
2022-02-18 18:17:27 +01:00
Stephan Kulow
f38bd3a7ed Target E128 - Continuation line under-indented for visual indent
https://www.flake8rules.com/rules/E128.html
2022-02-18 17:35:33 +01:00
Stephan Kulow
27c364b0c9 Target E251 - Unexpected spaces around keyword
https://www.flake8rules.com/rules/E251.html
2022-02-18 17:28:13 +01:00
Stephan Kulow
d8f5d0874e Remove E201 - Whitespace after '('
https://www.flake8rules.com/rules/E201.html
2022-02-18 17:23:19 +01:00
Stephan Kulow
54079e949f Target E202 - Whitespace before ')'
https://www.flake8rules.com/rules/E202.html
2022-02-18 17:18:29 +01:00
Stephan Kulow
529d1dafae Target E302 - add two comment lines before class 2022-02-18 17:15:48 +01:00
Stephan Kulow
4e9c8eabbe Target E305 - Have two empty lines of a class 2022-02-18 17:11:46 +01:00
Stephan Kulow
ae734ba555 Fix indent of statements E127
https://www.flake8rules.com/rules/E127.html
2022-02-18 14:23:59 +01:00
Stephan Kulow
f705a24db1 Only have one statement in a line E701
https://www.flake8rules.com/rules/E701.html
2022-02-18 13:42:57 +01:00
Stephan Kulow
52dbb52b7f
Merge pull request #2703 from coolo/drop_etree
Harmonize imports on using lxml for XML parsing
2022-02-18 12:50:18 +01:00
Stephan Kulow
1152d4c419 Remove bare excepts - https://www.flake8rules.com/rules/E722.html
The bare except in osc-credentials lead me to remove it and the scripts
using it
2022-02-18 12:03:56 +01:00
Stephan Kulow
e52dc6ce2b Harmonize imports on using lxml for XML parsing 2022-02-18 11:16:01 +01:00
Josef Reidinger
c838245a37 Refactor code to split big method and improve doc 2021-07-29 12:17:27 +02:00
Josef Reidinger
0f7b45c95f Add note about explicit ignoring of inherited maintainership 2021-07-28 09:51:35 +02:00