Пример #1
0
# The script searches the following files for configuration
#   ~/.config/bugzillarc
#   ~/.bugzillarc
#   $PWD/.bugzillarc
#
# The files are searched in that order.

import sys
from utilities import open_session, REST_URL


def set_bz_status(session, bugno, status):
    print(f"Setting the status on {bugno} to {status}:")

    r = session.put(f'{REST_URL}/bug/{bugno}', json={'status': status})

    r.raise_for_status()


if __name__ == '__main__':
    if len(sys.argv) < 3:
        print("Please include BZ bug number and status.")
        sys.exit(1)

    bugno = sys.argv[1]
    status = sys.argv[2]

    session = open_session()

    set_bz_status(session, bugno, status)
Пример #2
0
https://access.redhat.com/articles/11258

Users of {package} are advised to upgrade to these updated packages, which fix"""

if args.errata_type == "RHEA":
    synopsis += " enhancement update"
    solution += "these bugs and add these enhancements."
elif args.errata_type == "RHBA":
    synopsis += " bug fix and enhancement update"
    solution += "these bugs."
elif args.errata_type == "RHSA":
    pass

# Ensure bugs are in proper state (MODIFIED or VERIFIED) and that they have
# the appropriate rhel-fast-datapath flag set.
s = utilities.open_session()
bz_bugs = utilities.get_bz_bugs(s, args.bugs)
for bug in bz_bugs:
    if bug['status'] != 'MODIFIED' and bug['status'] != 'VERIFIED':
        utilities.update_bz(s, bug['id'], json={'status': 'MODIFIED'})
    utilities.set_bz_flag(s, bug['id'], f'fast-datapath-rhel-{release[-1]}',
                          '+')

e = Erratum(product='Fast-Datapath',
            release=release,
            errata_type=args.errata_type,
            security_impact=args.security_impact,
            synopsis=synopsis,
            topic=topic,
            description=description,
            solution=solution,