Skip to content
This repository has been archived by the owner on Apr 7, 2022. It is now read-only.

[1LP][RFR] Update authentication for bz util, add clone coverage #9643

Merged
merged 1 commit into from
Nov 22, 2019

Conversation

mshriver
Copy link
Member

@mshriver mshriver commented Nov 19, 2019

handle api_key authentication to bugzilla
remove contextmanager for login, the underlying library should authenticate when URL is passed
Add scan for clone BZs to the method used for BZ coverage reports

At this time, it takes a while (several minutes) to run when collecting clone BZ's. May be able to do some filtering to optimize, based on cross-cloning of BZ's.

Additional coverage list generated by this change:

    id: 1155295, qe_test_coverage: ?
    id: 1232022, qe_test_coverage: ?
    id: 1236683, qe_test_coverage: ?
    id: 1316137, qe_test_coverage: -
    id: 1335529, qe_test_coverage: -
    id: 1357013, qe_test_coverage: -
    id: 1382845, qe_test_coverage: -
    id: 1382847, qe_test_coverage: -
    id: 1385897, qe_test_coverage: -
    id: 1386782, qe_test_coverage: -
    id: 1388152, qe_test_coverage: -
    id: 1393120, qe_test_coverage: -
    id: 1396210, qe_test_coverage: -
    id: 1410828, qe_test_coverage: -
    id: 1411473, qe_test_coverage: -
    id: 1412364, qe_test_coverage: -
    id: 1413119, qe_test_coverage: -
    id: 1414887, qe_test_coverage: -
    id: 1433435, qe_test_coverage: -
    id: 1434965, qe_test_coverage: -
    id: 1437922, qe_test_coverage: -
    id: 1437925, qe_test_coverage: -
    id: 1437926, qe_test_coverage: -
    id: 1440574, qe_test_coverage: -
    id: 1441249, qe_test_coverage: -
    id: 1441251, qe_test_coverage: -
    id: 1442865, qe_test_coverage: -
    id: 1445900, qe_test_coverage: -
    id: 1446618, qe_test_coverage: -
    id: 1449366, qe_test_coverage: -
    id: 1450502, qe_test_coverage: -
    id: 1460316, qe_test_coverage: -
    id: 1460366, qe_test_coverage: -
    id: 1460809, qe_test_coverage: -
    id: 1470773, qe_test_coverage: -
    id: 1480377, qe_test_coverage: -
    id: 1498544, qe_test_coverage: -
    id: 1500051, qe_test_coverage: -
    id: 1500052, qe_test_coverage: -
    id: 1520977, qe_test_coverage: -
    id: 1521036, qe_test_coverage: -
    id: 1521043, qe_test_coverage: -
    id: 1524698, qe_test_coverage: -
    id: 1526081, qe_test_coverage: -
    id: 1532332, qe_test_coverage: -
    id: 1534770, qe_test_coverage: -
    id: 1535154, qe_test_coverage: -
    id: 1549241, qe_test_coverage: -
    id: 1553393, qe_test_coverage: -
    id: 1553396, qe_test_coverage: -
    id: 1553768, qe_test_coverage: -
    id: 1560098, qe_test_coverage: -
    id: 1560099, qe_test_coverage: -
    id: 1565139, qe_test_coverage: -
    id: 1569103, qe_test_coverage: -
    id: 1569104, qe_test_coverage: -
    id: 1571976, qe_test_coverage: -
    id: 1572711, qe_test_coverage: -
    id: 1578400, qe_test_coverage: -
    id: 1581287, qe_test_coverage: -
    id: 1583710, qe_test_coverage: -
    id: 1583711, qe_test_coverage: -
    id: 1588038, qe_test_coverage: -
    id: 1594839, qe_test_coverage: -
    id: 1595445, qe_test_coverage: -
    id: 1625376, qe_test_coverage: -
    id: 1634809, qe_test_coverage: -
    id: 1639364, qe_test_coverage: -
    id: 1641670, qe_test_coverage: -
    id: 1643263, qe_test_coverage: -
    id: 1646561, qe_test_coverage: -
    id: 1653710, qe_test_coverage: -
    id: 1672693, qe_test_coverage: -
    id: 1672694, qe_test_coverage: -
    id: 1693727, qe_test_coverage: -
    id: 1702075, qe_test_coverage: -
    id: 1704772, qe_test_coverage: -
    id: 1710578, qe_test_coverage: -
    id: 1722817, qe_test_coverage: -
    id: 1725894, qe_test_coverage: -
    id: 1728889, qe_test_coverage: -
    id: 1731992, qe_test_coverage: -
    id: 1732117, qe_test_coverage: -
    id: 1733376, qe_test_coverage: -
    id: 1733384, qe_test_coverage: -
    id: 1737123, qe_test_coverage: -
    id: 1740769, qe_test_coverage: -
    id: 1740844, qe_test_coverage: -
    id: 1741944, qe_test_coverage: -
    id: 1741945, qe_test_coverage: -
    id: 1767018, qe_test_coverage: ?
    id: 1767784, qe_test_coverage: ?
    id: 1767786, qe_test_coverage: ?
    id: 1767811, qe_test_coverage: ?
    id: 1767835, qe_test_coverage: ?
    id: 1773666, qe_test_coverage: ?
    id: 1773667, qe_test_coverage: ?
    id: 1774063, qe_test_coverage: ?

@mshriver mshriver requested a review from john-dupuy November 19, 2019 21:46
@mshriver mshriver changed the title [WIPTEST] Update authentication for bz util, add clone coverage [RFR] Update authentication for bz util, add clone coverage Nov 19, 2019
@mshriver mshriver requested a review from digitronik November 19, 2019 22:25
for bug_id, bug in zip(idlist, self.bugzilla.getbugs(idlist)):
# assign some attrs for each BZ
info[bug_id] = AttrDict(
description=bug.description,
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could set these by iterating over a list of fields, but that might be uglier.

Copy link
Contributor

@john-dupuy john-dupuy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome stuff @mshriver! I'm curious if there is any issue with duplicates? I.e. someone has marked a test case as automating both the clone and the original BZ -- will the clone appear twice? I guess since they are written to an AttrDict they will have the same key, so one will overwrite the other.

Maybe handling this could be a potential optimization? I doubt it would increase speed significantly however.

@mshriver
Copy link
Member Author

Correct @john-dupuy, if there are clones/coverage on multiple test cases this won't identify early, just end up overwriting the exiting element in the dictionary.

I'll take a look today at making it more optimized.

@john-dupuy john-dupuy changed the title [RFR] Update authentication for bz util, add clone coverage [1LP][RFR] Update authentication for bz util, add clone coverage Nov 21, 2019
handle api_key authentication to bugzilla
remove contextmanager for login, the underlying library should authenticate when URL is passed
Add scan for clone BZs to the method used for BZ coverage reports
@jawatts jawatts merged commit 9e7396a into ManageIQ:master Nov 22, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants