metrics: remove workaround for OBS xpath bug during request search.
Now that the bug related to openSUSE/open-build-service#5571 has been fixed the inverted behavior of exclude_target_projects no longer works. As such the argument should be removed and only way to get the desired behavior is to override include_request_from_project which includes request sourced from specific project. For the purposes of metrics only interested in requests targeting a specific project.
This commit is contained in:
parent
67200cdf5c
commit
0b342a5856
@ -39,6 +39,7 @@ def get_request_list(*args, **kwargs):
|
|||||||
osc.core.search = search_capture
|
osc.core.search = search_capture
|
||||||
osc.core._ET = osc.core.ET
|
osc.core._ET = osc.core.ET
|
||||||
osc.core.ET = ET
|
osc.core.ET = ET
|
||||||
|
osc.conf.config['include_request_from_project'] = False
|
||||||
|
|
||||||
osc.core.get_request_list(*args, **kwargs)
|
osc.core.get_request_list(*args, **kwargs)
|
||||||
|
|
||||||
@ -93,7 +94,6 @@ def timestamp(datetime):
|
|||||||
def ingest_requests(api, project):
|
def ingest_requests(api, project):
|
||||||
requests = get_request_list(api.apiurl, project,
|
requests = get_request_list(api.apiurl, project,
|
||||||
req_state=('accepted', 'revoked', 'superseded'),
|
req_state=('accepted', 'revoked', 'superseded'),
|
||||||
exclude_target_projects=[project],
|
|
||||||
withfullhistory=True)
|
withfullhistory=True)
|
||||||
for request in requests:
|
for request in requests:
|
||||||
if request.find('action').get('type') not in ('submit', 'delete'):
|
if request.find('action').get('type') not in ('submit', 'delete'):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user