2185 Commits

Author SHA1 Message Date
Jimmy Berry
88baa3bf65 Add parenthesis to print calls in osc-staging in preparation. 2017-01-24 22:21:53 -06:00
Jimmy Berry
eb58d336d3 Provide StagingAPI.get_prj_meta(). 2017-01-24 22:21:53 -06:00
Jimmy Berry
641c550023 Provide StagingAPI short-hand staging name API.
- extract_staging_short().
- prj_from_short()
- get_staging_projects_short()
2017-01-24 22:21:53 -06:00
Jimmy Berry
69f662685c Add RequestSplitter for common filtering and grouping or requests.
- re-implement list and adi commands using RequestSplitter
- numerous small cleanups and clarity improvements
- notably, adi now prints similar output to select when adding requests
- lxml is needed to provide more fully-featured xpath implementation
2017-01-24 22:21:10 -06:00
Ludwig Nussel
a2c4df2f56 Merge pull request #647 from DimStar77/s390x
Configure totest-manager for s390x
2017-01-23 12:01:05 +01:00
bad6c98050
Configure totest-manager for s390x 2017-01-20 11:46:42 +01:00
4f2afcfbcb Merge pull request #646 from lnussel/fate
Add FATE devel project to white list
2017-01-19 18:32:13 +01:00
Ludwig Nussel
ce01ceec23 Add FATE devel project to white list
In anticipation of a fate client submission
2017-01-19 16:55:21 +01:00
Ludwig Nussel
05bae74e78 Merge pull request #645 from lnussel/leapersle
Leaper tuning for SLE
2017-01-19 09:32:39 +01:00
Ludwig Nussel
da8e9d3c71 Leaper tuning for SLE 2017-01-18 17:04:19 +01:00
Ludwig Nussel
3c0b809563 limit history to workaround obs bug
obs doesn't honor the limit paramater for obs interconnect, so we
have to limit the loop ourselves
2017-01-18 17:04:18 +01:00
Ludwig Nussel
6079cf4359 Merge pull request #644 from jberry-suse/leaper-sle-origin
Leaper modification for SLE workflow
2017-01-18 13:49:02 +01:00
Ludwig Nussel
74d5072562 Merge pull request #642 from sbahling/config_limit
Make revision depth (limit) configurable
2017-01-18 11:03:03 +01:00
Jimmy Berry
de00cf092e Provide target_project in Leaper._check_factory() and use for SLE. 2017-01-17 22:30:34 -06:00
Jimmy Berry
ed667886ed leaper.py: disable parse_lookup() when running against ibs. 2017-01-17 22:26:43 -06:00
Jimmy Berry
604734b0f3 Provide ReviewBot.ibs to indicate if running against IBS. 2017-01-17 20:57:06 -06:00
Scott Bahling
211e503ea9 Make revision depth (limit) configurable
Adds --limit option to specify how many revisions back to iterate over
when checking for match. Leaving default at 5.
2017-01-17 13:03:35 +01:00
Ludwig Nussel
cfd19ca962 Merge pull request #619 from lnussel/apiswitch
Fetch request info from different api url
2017-01-17 10:49:03 +01:00
Bernhard M. Wiedemann
b4ab9057fd totest doc: fix typos and grammar 2017-01-13 17:36:36 +01:00
Ludwig Nussel
7671edfe7c Merge pull request #633 from lnussel/manager
Implement config for manager42
2017-01-13 17:27:06 +01:00
Ludwig Nussel
7b8e003521 Make config defaults a class variable 2017-01-13 15:36:34 +01:00
Ludwig Nussel
05710cb926 Merge pull request #636 from jberry-suse/ignore-factory
Correct indentation level of in requests_ignored check.
2017-01-13 15:31:31 +01:00
Ludwig Nussel
6fcdeb7a7f Make config defaults a class variable 2017-01-13 12:54:22 +01:00
58cdda7ef7 Merge pull request #638 from luigino/master
Added X11:GNUstep as project.
2017-01-13 18:24:49 +08:00
26fb7a884f Added X11:GNUstep as project. 2017-01-13 11:18:01 +01:00
7f18e332a0 Merge pull request #635 from nilxam/fix_compare_list
Force using expand in the api call and ignores the linking package
2017-01-13 12:39:08 +08:00
Jimmy Berry
6a521fc063 Correct indentation level of in requests_ignored check.
In the previous state this worked for any project except factory, now it
works on factory too.
2017-01-12 16:14:33 -06:00
264917f732 Force using expand in api call and ignore the linking package 2017-01-13 00:43:41 +08:00
Ludwig Nussel
e68120ae15 Merge pull request #632 from openSUSE/fix_comments_default
Fix comments default for openqa-maintenance bot
2017-01-12 13:03:08 +01:00
Ludwig Nussel
47a20b81b9 Merge pull request #631 from jberry-suse/request-ignore
Provide ignore/unignore request staging commands.
2017-01-12 11:34:02 +01:00
Ludwig Nussel
d72ef36cfc Merge pull request #634 from jberry-suse/origin-changed
leaper.py: indicate if origin differs from the expected origin.
2017-01-12 09:50:57 +01:00
Jimmy Berry
b25fda9b47 Provide ignore/unignore request staging commands.
It is not uncommon for a request to be in a pending state which requires
action beyond the scope of the staging workflow, but does not make sense
to deny the request. For lack of a "postponed" or "pending" state on OBS
a sudo-state of "ignore" is provided for the staging workflow. The ignore
state will remove a request from the "list" and "adi" commands so as not
to be accidentally staged. This avoids the need for keeping a context of
what requests should be ignored in one's memory.

It is expected that an ignored request will have comments reflecting what
is to be done or one should be added via the -m option of ignore command.
2017-01-11 18:32:23 -06:00
Jimmy Berry
6275fc52bc leaper.py: indicate if origin differs from the expected origin. 2017-01-11 14:37:26 -06:00
Ludwig Nussel
827333d3e4 Implement config for manager42
For example for Leap 42.3 it could look like this
2017-01-11 17:59:39 +01:00
Ludwig Nussel
dd26743202 Fetch request info from different api url 2017-01-11 17:43:11 +01:00
Ludwig Nussel
d21dbfb8c4 Merge pull request #629 from jberry-suse/osclib-cache
Provide cache for expensive and cache-able staging requests.
2017-01-11 17:26:15 +01:00
Jimmy Berry
cff5befed3 Provide cache for expensive and cache-able staging requests.
The two slowest staging API calls are for information that rarely changes.
By caching the result the commands typically execute over twice as fast.
Going further can see improvements of an order of magnitude or more by
caching almost all the GET requests.

In contrast to osclib/memoize.py this cache operates at the HTTP request
level. This has several advantages:

- Caches the expensive part (ie the HTTP request). There are a number of
  functions in osc.core and elsewhere that make the same API request, but
  process the result differently which would require multiple API calls
  using memoize.
- Handles cases were a loader function uses class attributes as input and
  output and thus no relevant method parameters or return. An important
  example is StagingAPI._generate_ring_packages().
- Storage is project aware which allows caches to be deleted when a project
  is known to have changed.
- Due to project awareness, can utilize OBS /statistics/latest_updated API
  call to determine which projects need to be expired.

The cache file structure is as follows:

- hostname(apiurl)
  - project
    - sha1(url)
  - sha1(url)

See Cache.PATTERNS for changing the time to live (ttl) or add patterns to
be cached.
2017-01-11 10:23:54 -06:00
Stephan Kulow
d6bb0b1129 Fix comments default for openqa-maintenance bot
And remove some of the noisy debug output
2017-01-11 13:35:33 +01:00
df7d88fab5 Merge pull request #623 from jberry-suse/osc-check_source-port
Port osc-check_source.py to ReviewBot as check_source.py.
2017-01-11 18:31:13 +08:00
Ludwig Nussel
9d55545080 Merge pull request #627 from nilxam/add_compare_list
Add compare_pkglist.py
2017-01-11 11:04:04 +01:00
Ludwig Nussel
7503c175e1 Merge pull request #628 from jberry-suse/devel-project-list
Provide a utility to print the list of devel projects for a given project.
2017-01-11 11:03:24 +01:00
Jimmy Berry
8db3461a00 Port osc-check_source.py to ReviewBot as check_source.py.
In the process of porting many improvements and bug fixes were added. Usage
follows the standard ReviewBot format and allows for new execution styles,
but the following examples replicate previous usage.

# Review all requests assigned to factory-auto.
./check_source.py --group factory-auto review

# Review request 13370.
./check_source.py --group factory-auto id 13370

# --project translates to project command.
# No longer automatically includes $project:NonFree.
./check_source.py --group factory-auto project openSUSE:Factory

New options available are:

--ignore-devel          ignore devel projects for target package
--devel-whitelist=FILE  file containing whitelisted projects (one per line)
--review-team=GROUP     review team group added to requests with > 8 diff
--repo-checker=USER     repo checker user added after accepted review

Note that --ignore-devel used to be provided as env[IGNORE_DEVEL_PROJECTS].

Some highlights about what was cleaned up:
- cryptic variable names replaced
- replaced custom osc queries with osc.core calls where applicable
- removed the need to load package information for all packages within
  target project which cuts runtime in half for single review
- removed extraneous code that performed extra steps for no reason
  os.path.dirname(os.path.realpath(__file__.replace('.pyc', '.py')))
  os.path.dirname(os.path.realpath(__file__))
  and _checker_prepare_dir() which needlessly chdir() twice.
- one logic branch failed to cleanup checkout directory
- new flags provide additional flexibility
2017-01-10 19:33:41 -06:00
Jimmy Berry
609a11c4d7 Provide a utility to print the list of devel projects for a given project. 2017-01-09 23:33:09 -06:00
Martin Pluskal
55ae25046c Merge pull request #630 from fschilling/updatekgrafthosts
Update kGraft host-list
2017-01-09 08:50:40 +01:00
schillingf
aa50704a46 Update kGraft host-list
* Add kgraft0h, kgraft0i, kgraft1b and kgraft1c.
* Remove kgraft09 (kernel out of support)
2017-01-08 19:52:38 +01:00
39df4abab1 Add compare_pkglist.py 2017-01-06 16:12:43 +08:00
Stephan Kulow
72d99f6041 Merge pull request #626 from fschilling/addkgrafthosts
Add hosts kgraft22 and kgraft23
2017-01-04 15:08:00 +01:00
schillingf
9db77eeaf0 Add hosts kgraft22 and kgraft23 2017-01-04 14:57:24 +01:00
Ludwig Nussel
7fe0322b70 Merge pull request #624 from jberry-suse/adi-clean
adi_command: whitespace cleanup.
2017-01-02 16:36:01 +01:00
Jimmy Berry
0ec78beb93 Remove duplicate ReviewBot.do_project(). (#621) 2017-01-02 09:37:35 +01:00