fix(review): drop libnull.rlib artifact + add Errors doc to ensure_config_pr_webhook
- Remove libnull.rlib accidentally committed in previous push (cargo check --no-default-features side-effect); add *.rlib to .gitignore to prevent recurrence - Add # Errors section to ensure_config_pr_webhook doc comment (argus: missing on pub async fn returning Result<()>)
This commit is contained in:
parent
d5a81f9195
commit
c4d2391455
3 changed files with 13 additions and 0 deletions
|
|
@ -307,6 +307,18 @@ pub async fn ensure_all() {
|
|||
///
|
||||
/// Called at startup alongside `knowledge::ensure_webhook`. No-op when the
|
||||
/// core token is absent (forge not yet provisioned).
|
||||
///
|
||||
/// # Errors
|
||||
///
|
||||
/// Returns an error if:
|
||||
/// - `dashboard_port` produces a URL that `url::Url::parse` rejects (should
|
||||
/// never happen for a valid port number).
|
||||
/// - The Forgejo `org_create_hook` API call fails (transport error, auth
|
||||
/// failure, or the `agent-configs` org does not exist).
|
||||
/// - The HTTP call times out (10 s limit).
|
||||
///
|
||||
/// Listing failures are treated as best-effort: they fall through to the
|
||||
/// create attempt rather than surfacing an error.
|
||||
pub async fn ensure_config_pr_webhook(core_token: &str, dashboard_port: u16) -> Result<()> {
|
||||
use forgejo_api::structs::{CreateHookOption, CreateHookOptionConfig, CreateHookOptionType};
|
||||
use std::collections::BTreeMap;
|
||||
|
|
|
|||
Loading…
Reference in a new issue