4444 Commits

Author SHA1 Message Date
Jimmy Berry
af0d74a2df StagingAPI: drop inferior expanded_repos() implementation for osclib.core. 2018-08-21 20:49:31 -05:00
Jimmy Berry
36a5a6c2e4 pkglistgen: utilize osclib.core.repository_path_expand(). 2018-08-21 20:49:31 -05:00
Jimmy Berry
a57fe7ba4e repo_checker: complete rework to handle arbitrary repos and maintenance.
The rework includes a variety of changes:

- multiple actions per request supported
- automatically detecting "main" repo (useful for devel/home projects)
- full layered repository path state and published taken into account
- arbitrary repository name (ie. not just standard) supported
- intermediate results (used for staging) no longer accept (even if no
  problems detected) until all layers are published
- no longer tied to staging process, but still supports staging workflow
- robust handling of repository state changes during review cycle
- multiple repositories supported for project_only output (ie. file name)
- project_only run supports any OBS project instead of only products
- maintenance_release requests supported with alternate staging approach
2018-08-21 20:49:26 -05:00
Jimmy Berry
341301fd0d osclib/util: provide sha1_short() adapted from repo_checker. 2018-08-21 20:47:37 -05:00
Jimmy Berry
7cb40bbe21 osclib/core: provide project_meta_revision() adapted from repo_checker. 2018-08-21 20:47:37 -05:00
Jimmy Berry
9f89eaad04 osclib/core: provide repository state and published functions. 2018-08-21 20:47:37 -05:00
Jimmy Berry
6e28fc4ec8 osclib/core: provide repository_path_search(). 2018-08-21 20:47:37 -05:00
Jimmy Berry
37540add5f osclib/core: provide repository_path_expand() adapted from StagingAPI. 2018-08-21 20:47:37 -05:00
Jimmy Berry
b6ab577a7f osclib/core: target_archs(): expose repository argument. 2018-08-21 20:47:37 -05:00
Jimmy Berry
6f9a81ff73 osclib/conf: drop main-repo default for all projects. 2018-08-21 20:47:37 -05:00
Jimmy Berry
53f7f42183 ReviewBot: utilize osclib.Cache for all bots by default.
Half the bots already utilize the Cache since it is used by StagingAPI
which they call, but really no reason for all of them not to use it by
default. With planned repo_checker changes the StagingAPI is not always
utilized, but it is desirable for the cache to always be used.

No sense calling Cache.init() in ReviewBot constructor as useless extra
calls when bots embed each other.
2018-08-21 01:56:05 -05:00
Jimmy Berry
3ece452a03 ReviewBot: utilize memoize cached config. 2018-08-21 01:53:29 -05:00
Jimmy Berry
d7d5724dae
Merge pull request #1655 from jberry-suse/pseudometa-container
osclib/core: provide project_pseudometa_*() functions (and related)
2018-08-20 21:03:44 -05:00
Jimmy Berry
1fe03c16f0 osc-staging: update "config" documentation to point to OSRT:Config. 2018-08-17 23:19:28 -05:00
Jimmy Berry
6d60708b59 osclib/core: source_file_save(): always include host in message. 2018-08-17 23:19:28 -05:00
Jimmy Berry
536e17cb79 osclib/stagingapi: rename dashboard_content_* methods to pseudometa_file_*.
No need to be confusing and use the deprecated dashboard name.
2018-08-17 23:19:24 -05:00
Jimmy Berry
24b15d6b0b Replace relevant 'dashboard' package references with pseudometa lookup.
Skipping some of the broader once which have no tangible impact, but are
expensive to change.
2018-08-17 23:18:32 -05:00
Jimmy Berry
5e6df089a6 osclib/stagingapi: drop {load,save}_file_content() methods.
Since the implementations have been made generic and dropped to osclib.core
there is not point in having wrappers in StagingAPI with the same args.
2018-08-17 22:15:58 -05:00
Jimmy Berry
26884da458 osclib/core: provide project_pseudometa_*() functions.
These methods provide for a generic place to store meta data related to
a project. For the time being, keep the original :Staging/dashboard
location for openSUSE products.
2018-08-17 22:11:28 -05:00
Jimmy Berry
89ab151a59 osclib/core: provide source_file_save() adapted from StagingAPI. 2018-08-17 22:07:14 -05:00
Jimmy Berry
c11f78eb83
Merge pull request #1651 from jberry-suse/conf-default-drop-staging
osclib/conf: remove staging default for generic projects.
2018-08-17 11:20:13 -05:00
Jimmy Berry
f0fadd6a05
Merge pull request #1650 from jberry-suse/conf-exclude-sub-projects
osclib/conf: exclude sub-projects from matching project patterns (and Leap:N:Update defaults)
2018-08-17 10:53:24 -05:00
Jimmy Berry
8092671ced
Merge pull request #1649 from jberry-suse/config-cached-get
osclib/conf: provide cached get() method to supersede ReviewBot cache.
2018-08-17 10:39:30 -05:00
Jimmy Berry
2180c4a2c6 ReviewBot: drop self.staging_config post switch to Config.get(). 2018-08-17 10:16:47 -05:00
Jimmy Berry
8cffc2e553 repo_checker: use osclib.conf.str2bool() instead of bool(). 2018-08-17 10:16:47 -05:00
Jimmy Berry
1012b62830 ReviewBots: utilize Config.get() instead of self.staging_config. 2018-08-17 10:16:47 -05:00
Jimmy Berry
5b5d917074 osclib/conf: provide cached get() method to supersede ReviewBot cache.
Given the slow migration of everything to the shared project config in
tools that change project contexts multiple times a consistent way of
accessing the config without forcing remote calls is needed.
2018-08-17 10:16:43 -05:00
Jimmy Berry
343213fb48 check_source: drop staging_group() for target_project_config().
The staging_group() method pre-dates the target_project_config(), but
essentially accomplishes the same for a single value.
2018-08-17 10:04:34 -05:00
Jimmy Berry
55116d31b5
Merge pull request #1648 from jberry-suse/config-decouple-and-require
osclib/conf: decouple from StagingAPI and always fetch remote config.
2018-08-17 10:02:37 -05:00
Jimmy Berry
93038db6fb
Merge pull request #1647 from jberry-suse/staging-setprio-optional-priority
osclib/prio: support non-important priority.
2018-08-17 09:54:42 -05:00
Jimmy Berry
5b44ea188d osclib/conf: provide Leap:N:Update default settings. 2018-08-17 00:08:09 -05:00
Jimmy Berry
f6550bfe87 osclib/conf: remove staging default for generic projects.
The original case was to enable remote config, but in general and with
up-coming changes having the staging setting falsely set like this is not
ideal. Since the remote config is loaded via attribute this does not even
affect it anymore. The proper change is to make the "dashboard" container
configurable which is planned.
2018-08-17 00:03:59 -05:00
Jimmy Berry
77e27fae9e osclib/conf: exclude sub-projects from matching project patterns.
Otherwise, :Update projects match the primary product settings which
gives the wrong impression to tools as things like :Update:Staging do
not exist. Since :Update and other sub-projects are in a different phase
of development they should really have separate settings. :Ports however
does have stagings and in theory should act like parent product. If it
becomes desirable to split that can be done in the future.

Some policy settings related to ReviewBots likely are desirable to carry
over, but that can be resolved in follow-up as they are not currently used.
2018-08-16 23:50:23 -05:00
Jimmy Berry
0696a0fe6c osclib/stagingapi: utilize osclib.core.attribute_value_*() implementations.
Provides convenience aliases that require less arguments.
2018-08-16 22:01:46 -05:00
Jimmy Berry
dace1c3997 tests/obs: improve format of default Config attribute. 2018-08-16 21:54:20 -05:00
Jimmy Berry
760ddf39e6 osclib/conf: decouple from StagingAPI and always fetch remote config.
As the remote config is no longer optional for SLE and is utilized by
openSUSE to the point were it is dangerous not to load the remote config
it should be required. Currently only certain users call apply_remote()
while this will make it built-in during construction and thus makes the
usage consistent and no longer require StagingAPI.
2018-08-16 21:53:40 -05:00
Jimmy Berry
68c3150069 osclib/conf: utilize osclib.core.attribute_value_load() instead of StagingAPI. 2018-08-16 21:42:58 -05:00
Jimmy Berry
65be714632 osclib/conf: drop dashboard/config migration to attribute.
Should no longer be needed and provides one less dependency on StagingAPI
which will be removed from Config class.
2018-08-16 21:41:14 -05:00
Jimmy Berry
8bdf571154 osclib/core: provide attribute_value_(load|save) adapted from StagingAPI. 2018-08-16 21:38:11 -05:00
Jimmy Berry
a90bf0e07b osc-staging: add documentation for setprio command. 2018-08-16 18:05:25 -05:00
Jimmy Berry
9c0eb82f51 osclib/prio: support non-important priority. 2018-08-16 18:05:20 -05:00
Jimmy Berry
fb3d58024a
Merge pull request #1646 from jberry-suse/core-maintainers_get-correction
osclib/core: maintainers_get(): rework to properly supports groups.
2018-08-16 17:29:37 -05:00
Jimmy Berry
7b0f75667c
Merge pull request #1644 from jberry-suse/repo_checker-CreatePackageDescr-remove-special-ignore
repo_checker: CreatePackageDescr: remove more unnecessary special cases.
2018-08-16 17:19:49 -05:00
Jimmy Berry
ffcee027c0 osclib/core: maintainers_get(): rework to properly supports groups.
Previously, group members were only added if no maintainers were present
whereas group members should always be considered. Additionally, project
queries never included group members. Now groups are included in both.
2018-08-16 00:31:37 -05:00
Jimmy Berry
038bec6113 osclib/core: provide groups_members() to expand muliple groups users. 2018-08-16 00:27:37 -05:00
Jimmy Berry
600a486745 Utilize ET.fromstringlist() intead of joining strings. 2018-08-16 00:26:53 -05:00
Jimmy Berry
ca55bed494 repo_checker: CreatePackageDescr: remove more unnecessary special cases. 2018-08-15 23:06:14 -05:00
Jimmy Berry
fa1f929d19
Merge pull request #1633 from jberry-suse/repo_checker-automate-whitelist
repo_checker: determine existing problems based on project_only output.
2018-08-15 17:29:37 -05:00
Jimmy Berry
2809f3934a repo_checker: drop whitelist_clean sub-command.
No longer needed since the whitelist is no longer managed manually.
2018-08-15 16:43:48 -05:00
Jimmy Berry
9fdea5fbee repo_checker: determine existing problems based on project_only output.
The project level whitelist stored in config is no longer utilized, but
staging level overrides are still available.
2018-08-15 16:43:00 -05:00