influxdata/influxdb · error · PluginError

error fetching plugin from repository

Error message

error fetching plugin from repository: {0} {1}

What it means

PluginError::FetchingFromRepository(status, body) is thrown when an HTTP GET to the plugin repository returns a non-success status code; the status code and response body are embedded in the message. The library throws it inside plugin download/install flows when reqwest reports an error response.

Solutions

  1. Check the embedded status code: fix the URL if 404, add authentication/rate-limit token if 403, retry later if 5xx.
  2. Verify network/proxy connectivity to the repository host with curl.
  3. Pre-install the plugin into the configured plugin directory to bypass remote fetching.

Example fix

// before (anonymous GitHub API call, 403 rate limit)
GET https://api.github.com/repos/org/repo/contents/plugin.py
// after (with token)
reqwest::Client::new().get(url).header("Authorization", format!("Bearer {token}"))
Defensive patterns

Strategy: retry

Validate before calling

// pre-check URL reachability
const res = await fetch(repoUrl, {method: 'HEAD'});
if (!res.ok) throw new Error(`repo pre-check failed: ${res.status}`);

Try / catch

match install_result {
    Err(PluginError::FetchingFromRepository(status, body)) if status == 403 || status.as_u16() >= 500 => retry_with_backoff(),
    Err(PluginError::FetchingFromRepository(StatusCode::NOT_FOUND, _)) => fix_plugin_url(),
    Err(e) => return Err(e),
    Ok(p) => Ok(p),
}

Prevention

When it happens

Trigger: Installing a plugin from a remote repository (e.g. GitHub) where the URL returns 404 (plugin doesn't exist), 403 (rate-limited/private repo), or 5xx.

Common situations: Misspelled GitHub org/repo/path in the plugin URL; hitting GitHub API rate limits without auth token; private repository requiring credentials; offline/proxy issues causing gateway errors.

Understand the failure class

Background: "API error: {status}" and "HTTP 401/403/404/429/5xx" errors: non-2xx HTTP responses explained — this error's family across 27 libraries.

Related errors


AI-assisted analysis of influxdata/influxdb@06200ef96b (2026-09-19). Data as JSON: /api/errors/efab795d0ed841b0. Report an issue: GitHub.

Appendix: source

Thrown at influxdb3_processing_engine/src/plugins.rs:65

    #[error(transparent)]
    AnyhowError(#[from] anyhow::Error),

    #[error("reading plugin file: {0}")]
    ReadPluginError(#[from] std::io::Error),

    #[error("error executing plugin: {0}")]
    PluginExecutionError(#[from] influxdb3_py_api::error::ExecutePluginError),

    #[error("invalid cron syntax: {0}")]
    InvalidCronSyntax(#[from] cron::error::Error),

    #[error("cron schedule never triggers: {0}")]
    CronScheduleNeverTriggers(String),

    #[error("non-schedule plugin with schedule trigger: {0}")]
    NonSchedulePluginWithScheduleTrigger(String),

    #[error("error fetching plugin from repository: {0} {1}")]
    FetchingFromRepository(reqwest::StatusCode, String),

    #[error(
        "plugin installation is disabled; plugins must already exist in the configured plugin directory"
    )]
    PluginInstallationDisabled,

    #[error("Join error, please report: {0}")]
    JoinError(#[from] tokio::task::JoinError),

    #[error("Node not configured with plugin directory")]
    NoPluginDir,

    #[error(
        "Path traversal detected: plugin filename '{0}' attempts to access files outside the plugin directory"
    )]
    PathTraversal(String),
}

View on GitHub (pinned to 06200ef96b)