Commit graph

1084 commits

Author SHA1 Message Date
Mike McLean
a9f3afdef7 whitespace: adjust indentations 2019-10-09 08:41:15 -04:00
Mike McLean
c49660be33 hub: use joinpath instead of os.path.join 2019-10-09 08:41:15 -04:00
Tomas Kopecek
873a159e08 drop unused host.repoAddRPM call
Fixes: https://pagure.io/koji/issue/1655
2019-10-09 09:17:20 +02:00
Tomas Kopecek
b8017bfff5 docs for build.extra.source
Fixes: https://pagure.io/koji/issue/1673
2019-10-09 09:14:04 +02:00
Tomas Kopecek
ff57615460 Subselect gives better performance
Original query based on JOINs is 1000x slower in better cases. Sub-query
helps a lot here.

Fixes: https://pagure.io/koji/issue/1674
2019-10-09 09:12:47 +02:00
Tomas Kopecek
0d6d9a51a6 swapped values in message
Related: https://pagure.io/koji/issue/1090
2019-10-03 16:03:03 +02:00
Yu Ming Zhu
2e8611254c fix unavailable id column 2019-09-30 15:47:56 +02:00
Yu Ming Zhu
24afeca663 hub: [groupListRemove] raise Error when no group for tag
Fixes: https://pagure.io/koji/issue/1090
2019-09-30 15:47:45 +02:00
Pat Riehecky
f3ace6b400 hub: add missing package list check 2019-09-30 15:22:54 +02:00
Tomas Kopecek
3de3f61fbb move tag/package owners to separate table
Changing owner is triggering repo regeneration in kojira. As it is
something which doesn't have any effect on repodata, let's put it to
separate table and let kojira ignore these changes.

Fixes: https://pagure.io/koji/issue/956
2019-08-29 15:44:24 +02:00
Tomas Kopecek
bf5da96053 Fix lookup_name usage + tests
Fixes: https://pagure.io/koji/issue/1632
2019-08-28 15:46:02 +02:00
Mike McLean
da1153fc33 raise an error when adding an archive of the wrong type 2019-08-28 15:17:27 +02:00
Mike McLean
ba83f877ff correct error text 2019-08-28 15:17:27 +02:00
Mike McLean
b67de2c26e pass correct buildinfo to callbacks 2019-08-19 11:07:43 -04:00
Mike McLean
a5f2d582cc rework update of reserved builds
Fixes: https://pagure.io/koji/issue/1603
2019-08-16 17:19:57 -04:00
Mike McLean
2a00b1a7a2 fix btype lookup in list_archive_files()
Fixes: https://pagure.io/koji/issue/1507
2019-08-15 17:00:51 -04:00
Tomas Kopecek
07f0cba77a use right top limit
randint's top limit is included in range, so original value 256 can be
reached and as such hex-digit 100 is emitted enlarging the string.

Fixes: https://pagure.io/koji/issue/1611
2019-08-14 11:20:00 +02:00
Tomas Kopecek
dfbe322222 deprecate sha1/md5_constructor from koji.util
These functions are now fully provided by hashlib. Commit removes their
usage from koji's codebase and leaves deprecation message in lib.

Final removal from lib is scheduled to 1.21.

Fixes: https://pagure.io/koji/issue/1487
2019-08-12 16:07:55 -04:00
Mike McLean
8ecfb4dc5b pull owner from correct place
Fixes https://pagure.io/koji/issue/1604

In this function, we have binfo, buildinfo, and self.buildinfo.
A little confusing ;)

Note that self.buildinfo['owner'] is validated in prep_build()
2019-08-06 15:35:33 -04:00
Tomas Kopecek
bf7bd1c1af copy updated policy for reserved cg builds
Fixes: https://pagure.io/koji/issue/1599
2019-08-06 14:31:24 -04:00
Tomas Kopecek
4c0caecca8 fix recycling build due to cg
Fixes: https://pagure.io/koji/issue/1598
2019-08-06 10:25:14 -04:00
Tomas Kopecek
64f734631b Backward-compatible fix for CG import
User needn't to be specified during CG import. In such case actual user
should be the owner.

Fixes: https://pagure.io/koji/issue/1596
2019-08-02 14:46:58 +02:00
Tomas Kopecek
9b72831bdf secrets import is missing 'else' variant
Later in code 'secrets' is tested for its existence, so it should be set
to None if it wasn't imported.

Fixes: https://pagure.io/koji/issue/1590
2019-08-01 15:37:57 -04:00
Tomas Kopecek
8abc2471ca use _writeInheritanceData in _create_tag
Fixes: https://pagure.io/koji/issue/1554
2019-07-31 15:24:15 -04:00
Mike McLean
1f52e60839 only check epoch against reservation if it is given 2019-07-16 10:41:43 -04:00
Mike McLean
b5517d16d5 default epoch to None in cg_init_build() 2019-07-16 10:33:16 -04:00
Mike McLean
5b12221bc8 error if reservation token given without build_id 2019-07-16 10:26:25 -04:00
Mike McLean
6caca35f4d clear reservation when cg build completes 2019-07-16 10:11:55 -04:00
Tomas Kopecek
f1d2ebc85c move cg_id to build table 2019-07-16 10:11:55 -04:00
Tomas Kopecek
8da8420c65 better error messages 2019-07-16 10:11:55 -04:00
Tomas Kopecek
c38c024ac5 extended getBuild to return reservations 2019-07-16 10:11:55 -04:00
Tomas Kopecek
25bfb2a94b delete tokens on cancelBuild 2019-07-16 10:11:55 -04:00
Tomas Kopecek
f6a845c870 restrict to cg_id 2019-07-16 10:11:55 -04:00
Tomas Kopecek
0aa00d0bb2 remove debug 2019-07-16 10:11:55 -04:00
Tomas Kopecek
707d2b2b00 move token from metadata to api option 2019-07-16 10:11:55 -04:00
Tomas Kopecek
f2647a687b use token for reservation 2019-07-16 10:11:54 -04:00
Tomas Kopecek
395cf0f76e remove debug print 2019-07-16 10:11:54 -04:00
Tomas Kopecek
d35163a726 leave recycle_build untouched 2019-07-16 10:11:54 -04:00
Tomas Kopecek
7fbcf87df2 move init_build out of CG_Importer 2019-07-16 10:11:54 -04:00
Tomas Kopecek
69bf20bc25 reverse wrong strict logic 2019-07-16 10:11:54 -04:00
Tomas Kopecek
2ab101c381 raise an error on repeated call cgInitBuild for same nvr 2019-07-16 10:11:54 -04:00
Tomas Kopecek
553871be9e API for reserving NVRs for content generators
Fixes: https://pagure.io/koji/issue/1463
2019-07-16 10:11:54 -04:00
Tomas Kopecek
61c015357b use list for db instead of set 2019-07-09 13:34:36 -04:00
Tomas Kopecek
b7d273b2fa API/CLI/tests for notification blocks 2019-07-09 13:34:36 -04:00
Tomas Kopecek
e4c37dfffb notification optout tests
Related: https://pagure.io/koji/issue/1204
2019-07-09 13:34:36 -04:00
Mike McLean
6ae165f77b apply opt-outs in get_notification_recipients 2019-07-09 13:34:36 -04:00
Mikolaj Izdebski
de161628b0 Allow hub policy to match version and release
Fixes https://pagure.io/koji/issue/1134

Based on work from https://pagure.io/koji/pull-request/1135
2019-06-26 11:44:23 -04:00
Jana Cupova
421437b52b Drop new line 2019-06-17 16:45:02 -04:00
Jana Cupova
9ae15acf54 Fix typo in getArchiveTypes dosctring 2019-06-17 16:45:02 -04:00
Tomas Kopecek
b0f0c3ff45 New 'buildtype' test for policies
Fixes: https://pagure.io/koji/issue/1225
2019-06-14 15:54:42 -04:00