BUGZILLA(1)
π BUGZILLA(1) β User Commands π
okay bestie, welcome to the bugzilla(1) manual β itβs the command line tool for interacting with a Bugzilla, and itβs giving main character energy for your terminal. letβs go π
β¨
πΈ NAME πΈ
bugzilla β command line tool for interacting with Bugzilla. periodt. π
β¨ SYNOPSIS β¨
bugzilla [options] [command] [command-options]
π¦ DESCRIPTION π¦
bugzilla is a command line tool for interacting with a Bugzilla instance over REST or XMLRPC. no cap.
command is one of:
loginβ log into the given bugzilla instancenewβ create a new bugqueryβ search for bugs matching given criteriamodifyβ modify existing bugsattachβ attach files to existing bugs, or get attachmentsinfoβ get info about the given bugzilla instance
π GLOBAL OPTIONS π
--help,-hβ syntax:-h. show this help message and exit. iconic. β¨--bugzillaβ syntax:--bugzilla BUGZILLA. The bugzilla URL. Full API URLs are typically like:
* https://bugzilla.example.com/xmlrpc.cgi # XMLRPC API
* https://bugzilla.example.com/rest/ # REST API
If a non-specific URL is passed, like 'bugzilla.redhat.com', bugzilla will try to probe whether the expected XMLRPC or REST path is available, preferring XMLRPC for backwards compatibility.
The default URL is https://bugzilla.redhat.com. π
--nosslverifyβ syntax:--nosslverify. Don't error on invalid bugzilla SSL certificate. bestie, be careful. π«Ά--certβ syntax:--cert CERTFILE. client side certificate file needed by the webserver.--loginβ syntax:--login. Run interactive"login"before performing the specified command.--usernameβ syntax:--username USERNAME. Log in with this username.--passwordβ syntax:--password PASSWORD. Log in with this password.--restrict-loginβ syntax:--restrict-login. The session (login token) will be restricted to the current IP address.--ensure-logged-inβ syntax:--ensure-logged-in. Raise an error if we aren't logged in to bugzilla. Consider using this if you are depending on cached credentials, to ensure that when they expire the tool errors, rather than subtly change output. lowkey important. π--no-cache-credentialsβ syntax:--no-cache-credentials. Don't save any bugzilla tokens to disk, and don't use any pre-existing credentials.--tokenfileβ syntax:--tokenfile TOKENFILE. token file to use for bugzilla authentication.--verboseβ syntax:--verbose. give more info about what's going on.--debugβ syntax:--debug. output bunches of debugging info. π--versionβ syntax:--version. show program's version number and exit.
π§Έ STANDARD BUGZILLA OPTIONS π§Έ
These options are shared by some combination of the 'new', 'query', and 'modify' sub commands. Not every option works for each command though. iykyk.
-p,--productβ syntax:--product PRODUCT. Product name.-v,--versionβ syntax:--version VERSION. Product version.-c,--componentβ syntax:--component COMPONENT. Component name.-s,--summaryβ syntax:--summary SUMMARY. Bug summary.-l,--commentβ syntax:--comment DESCRIPTION. Set initial bug comment/description.--comment-tagβ syntax:--comment-tag TAG. Comment tag for the new comment.--sub-componentβ syntax:--sub-component SUB_COMPONENT. RHBZ sub component name.-o,--osβ syntax:--os OS. Operating system.--archβ syntax:--arch ARCH. Arch this bug occurs on.-x,--severityβ syntax:--severity SEVERITY. Bug severity.-z,--priorityβ syntax:--priority PRIORITY. Bug priority.--aliasβ syntax:--alias ALIAS. Bug alias (name).-s,--statusβ syntax:--status STATUS. Bug status (NEW,ASSIGNED, etc.).-u,--urlβ syntax:--url URL. URL for further bug info.-m --target_milestoneβ syntax:--target_milestone TARGET_MILESTONE. Target milestone.--target_releaseβ syntax:--target_release TARGET_RELEASE. RHBZ Target release.--blockedβ syntax:...]. Bug IDs that this bug blocks.--dependsonβ syntax:...]. Bug IDs that this bug depends on.--keywordsβ syntax:...]. Bug keywords.--groupsβ syntax:...]. Which user groups can view this bug.--ccβ syntax:...]. CC list.-a,--assignee,--assigned_toβ syntax:--assigned_to ASSIGNED_TO. Bug assignee.-q,--qa_contactβ syntax:--qa_contact QA_CONTACT. QA contact.-f,--flagβ syntax:--flag FLAG. Set or unset a flag. For example, to set a flag nameddevel_ack, do--flag devel_ack+Unset a flag with the'X'value, like--flag needinfoX.--tagsβ syntax:--tags TAG. Set (personal) tags field.-w,--whiteboardβ syntax:--whiteboard WHITEBOARD. Whiteboard field.--devel_whiteboardβ syntax:--devel_whiteboard DEVEL_WHITEBOARD. RHBZ devel whiteboard field.--internal_whiteboardβ syntax:--internal_whiteboard INTERNAL_WHITEBOARD. RHBZ internal whiteboard field.--qa_whiteboardβ syntax:--qa_whiteboard QA_WHITEBOARD. RHBZ QA whiteboard field.-F,--fixed_inβ syntax:--fixed_in FIXED_IN. RHBZ'Fixed in version'field.--fieldβ syntax:--field FIELD=VALUE. Manually specify a bugzilla API field.FIELDis the raw name used by the bugzilla instance. For example if your bugzilla instance has a custom fieldcf_my_field, do:--field cf_my_field=VALUE.--field-jsonβ syntax:--field-json JSONSTRING. Specify--fielddata as a JSON string. Example:--field-json '{"cf_my_field": "VALUE", "cf_array_field": [1, 2]}'.
π OUTPUT OPTIONS π
These options are shared by several commands, for tweaking the text output of the command results. slay.
--fullβ syntax:--full. output detailed bug info.-i,--idsβ syntax:--ids. output only bug IDs.-e,--extraβ syntax:--extra. output additional bug information (keywords, Whiteboards, etc.).--onelineβ syntax:--oneline. one line summary of the bug (useful for scripts).--jsonβ syntax:--json. output bug contents in JSON format.--includefieldβ syntax:--includefield. Pass the field name to bugzillainclude_fieldslist. Only the fields passed toinclude_fieldsare returned by the bugzilla server. This can be specified multiple times.--extrafieldβ syntax:--extrafield. Pass the field name to bugzillaextra_fieldslist. When used with--jsonthis can be used to request bugzilla to return values for non-default fields. This can be specified multiple times.--excludefieldβ syntax:--excludefield. Pass the field name to bugzillaexclude_fieldslist. When used with--jsonthis can be used to request bugzilla to not return values for a field. This can be specified multiple times.--rawβ syntax:--raw. raw output of the bugzilla contents. This format is unstable and difficult to parse. Please use the--jsoninstead if you want maximum output from the bugzilla. bestie, don't parse raw. just don't. π--outputformatβ syntax:--outputformat OUTPUTFORMAT. Print output in the form given. You can use RPM-style tags that match bug fields, e.g.:'%{id}: %{summary}'.
The output of the bugzilla tool should NEVER BE PARSED unless you are using a custom --outputformat. For everything else, just don't parse it, the formats are not stable and are subject to change. periodt. π₯
--outputformat allows printing arbitrary bug data in a user preferred format. For example, to print a returned bug ID, component, and product, separated with ::, do:
--outputformat "%{id}::%{component}::%{product}"
The fields (like 'id', 'component', etc.) are the names of the values returned by bugzilla's API. To see a list of all fields, check the API documentation in the 'SEE ALSO' section. Alternatively, run a 'bugzilla --debug query ...' and look at the key names returned in the query results. Also, in most cases, using the name of the associated command line switch should work, like --bug_status becomes %{bug_status}, etc.
π βQUERYβ SPECIFIC OPTIONS π
Certain options can accept a comma separated list to query multiple values, including --status, --component, --product, --version, --id.
Note: querying via explicit command line options will only get you so far. See the --from-url option for a way to use powerful Web UI queries from the command line.
-b,--bug_id,--idβ syntax:--id ID. specify individual bugs by IDs, separated with commas.-r,--reporterβ syntax:--reporter REPORTER. Email: search reporter email for given address.--quicksearchβ syntax:--quicksearch QUICKSEARCH. Search using bugzilla's quicksearch functionality.--savedsearchβ syntax:--savedsearch SAVEDSEARCH. Name of a bugzilla saved search. If you don't own this saved search, you must passed--savedsearch_sharer_id.--savedsearch-sharer-idβ syntax:--savedsearch-sharer-id SAVEDSEARCH_SHARER_ID. Owner ID of the--savedsearch. You can get this ID from the URL bugzilla generates when running the saved search from the web UI.--from-urlβ syntax:--from-url WEB_QUERY_URL. Make a working query via bugzilla's'Advanced search'web UI, grab the url from your browser (the string withquery.cgiorbuglist.cgiin it), and--from-urlwill run it via the bugzilla API. Don't forget to quote the string! This only works for Bugzilla 5 and Red Hat bugzilla. π
π οΈ βMODIFYβ SPECIFIC OPTIONS π οΈ
Fields that take multiple values have a special input format.
Append: --cc=foo@example.com
Overwrite: --cc==foo@example.com
Remove: --cc=-foo@example.com
Options that accept this format: --cc, --blocked, --dependson, --groups, --tags, whiteboard fields.
-k,--close RESOLUTIONβ syntax:RESOLUTION. Close with the given resolution (WONTFIX,NOTABUG, etc.).-d,--dupeidβ syntax:--dupeid ORIGINAL. ID of original bug. Implies--close DUPLICATE.--privateβ syntax:--private. Mark new comment as private.--reset-assigneeβ syntax:--reset-assignee. Reset assignee to component default.--reset-qa-contactβ syntax:--reset-qa-contact. Reset QA contact to component default.--minor-updateβ syntax:--minor-update. Request bugzilla to not send any email about this change. lowkey sneaky but okay. π
π£ βNEWβ SPECIFIC OPTIONS π£
--privateβ syntax:--private. Mark new comment as private.
π βATTACHβ OPTIONS π
-f,--fileβ syntax:--file FILENAME. File to attach, or filename for data provided on stdin.-d,--descriptionβ syntax:--description DESCRIPTION. A short description of the file being attached.-t,--typeβ syntax:--type MIMETYPE. Mime-type for the file being attached.-g,--getβ syntax:--get ATTACHID. Download the attachment with the given ID.--getallβ syntax:--getall BUGID. Download all attachments on the given bug.--ignore-obsoleteβ syntax:--ignore-obsolete. Do not download attachments marked as obsolete.-l,--commentβ syntax:--comment COMMENT. Add comment with attachment.
β¨ βINFOβ OPTIONS β¨
okay so these are the info-gathering girlies β no bug editing, just metadata. π
-p,--productsβ Syntax:--products. Get a list of products. That's it, that's the whole vibe. ποΈ-c,--componentsβ Syntax:--components PRODUCT. List the components in the given product. You gotta pass a PRODUCT. π§©-o,--component_ownersβ Syntax:--component_owners PRODUCT. List components (and their owners). So you get the component plus who's responsible for it. π-v,--versionsβ Syntax:--versions PRODUCT. List the versions for the given product. Version check but make it bugzilla. π¦--active-componentsβ Syntax:--active-components. Only show active components. Combine with--components*. So it's like a filter for the active girlies only. β¨
π BUGZILLARC CONFIG FILE π
Both bugzilla and the python-bugzilla library will read a bugzillarc config file if it is present in these locations:
/etc/bugzillarc~/.bugzillarc~/.config/python-bugzilla/bugzillarc
The contents of the files are processed and merged together in the order they are listed above. So yeah, they stack. π«Ά
The main usage for bugzillarc is to store API keys for your bugzilla URLs:
[bugzilla.example.com]
api_key=INSERT-YOUR-API-KEY-HERE
[bugzilla.redhat.com]
api_key=MY-REDHAT-API-KEY-BLAH
The sections must be hostnames. Other values that can be set per hostname section are
user: default auth usernamepassword: default auth passwordcert: default client side certificate
A [DEFAULTS] section is also accepted, which takes the following values:
url: default bugzilla URL
π AUTHENTICATION CACHE AND API KEYS π
Some command usage will require an active login to the bugzilla instance. For example, if the bugzilla instance has some private bugs, those bugs will be missing from query output if you do not have an active login. So private bugs ghost you. π»
If you are connecting to a bugzilla 5.0 or later instance, the best option is to use bugzilla API keys. From the bugzilla web UI, log in, navigate to Preferences->API Keys, and generate a key (it will be a long string of characters and numbers). It's giving secret password but make it API. π
Then use bugzilla --bugzilla URL login --api-key, which will ask for the API key, and save it to bugzillarc for you. Bestie behavior. π«Ά
For older bugzilla instances, you will need to cache a login token with the "login" subcommand or the "--login" argument. Old school, still valid. π
Additionally, the --no-cache-credentials option will tell the bugzilla tool to not save or use any authentication cache, including the bugzillarc file. No caching, no remembering, just vibes. π
π EXAMPLES π
bugzilla query --bug_id 62037
bugzilla query --version 15 --component python-bugzilla
bugzilla login
bugzilla new -p Fedora -v rawhide -c python-bugzilla \
--summary "python-bugzilla causes headaches" \
--comment "python-bugzilla made my brain hurt when I used it."
bugzilla attach --file ~/Pictures/cam1.jpg --desc "me, in pain"
$BUGID
bugzilla attach --getall $BUGID
bugzilla modify --close NOTABUG --comment "Actually, you're
hungover." $BUGID
π¦ EXIT STATUS π¦
bugzilla normally returns 0 if the requested command was successful. Otherwise, exit status is:
1if bugzilla is interrupted by the user (or a login attempt fails)2if a socket error occurs (e.g. TCP connection timeout)3if the Bugzilla server throws an error
π BUGS π
Please report any bugs as github issues at https://github.com/python-bugzilla/python-bugzilla
π SEE ALSO π
https://bugzilla.readthedocs.io/en/latest/api/index.htmlhttps://bugzilla.redhat.com/docs/en/html/api/core/v1/bug.html
and that's the whole BUGZILLA(1) page, bestie! The footer is just BUGZILLA(1) β no version, no date, just the name β so that's the tea. Mwah! ππ«Άβ¨
π¦ where this page comes from
- debian trixie: bugzilla-cli 3.3.0-1 Β· GPL-2.0-or-later
- epel 10: python-bugzilla-cli 3.3.0-1.el10_0 Β· GPL-2.0-or-later
- fedora 43: python-bugzilla-cli 3.3.0-6.fc43 Β· GPL-2.0-or-later
- fedora 44: python-bugzilla-cli 3.3.0-7.fc44 Β· GPL-2.0-or-later
- nixos 26.05: python3.13-python-bugzilla 3.3.0
- nixos 26.05: python3.14-python-bugzilla 3.3.0
- nixpkgs unstable: python3.13-python-bugzilla 3.3.0
- nixpkgs unstable: python3.14-python-bugzilla 3.3.0
- ubuntu resolute: bugzilla-cli 3.3.0-1 Β· GPL-2.0-or-later
- ubuntu stonking: bugzilla-cli 3.3.0-1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms