forked frommsuchane/bugzilla_query
- Notifications
You must be signed in to change notification settings - Fork0
Access bugs on a remote Bugzilla instance from Rust
License
NotificationsYou must be signed in to change notification settings
redhat-documentation/bugzilla_query
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Access bugs on a remote Bugzilla instance.
Thebugzilla_query
crate is a Rust library that can query a Bugzilla instance using its REST API. It returns a strongly typed representation of the requested bugs.
This library provides no functionality to create or modify bugs. The access is read-only.
Without logging in, search for a single bug and check for its assignee:
use tokio;use bugzilla_query::BzInstance;#[tokio::main]asyncfnmain() ->Result<(),Box<dynError>>{let bugzilla =BzInstance::at("https://bugzilla.redhat.com".to_string())?;let bug = bugzilla.bug("1906883").await?;assert_eq!(bug.assigned_to,"Marek Suchánek");Ok(())}
Use an API key to log into Bugzilla. Search for all bugs on Fedora 36 that belong to therust
component. Check that there is more than one bug:
use tokio;use bugzilla_query::{Auth,BzInstance,Pagination};#[tokio::main]asyncfnmain() ->Result<(),Box<dynError>>{let bugzilla =BzInstance::at("https://bugzilla.redhat.com".to_string())?.authenticate(Auth::ApiKey("My API Key".to_string())).paginate(Pagination::Unlimited);let query ="component=rust&product=Fedora&version=36";let bugs = bugzilla.search(query).await?;assert!(bugs.len() >1);Ok(())}
jira_query
, a similar interface to Jira
About
Access bugs on a remote Bugzilla instance from Rust
Resources
License
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
No packages published
Languages
- Rust100.0%