influxdata/influxdb · error · PluginEnvironmentError

Package installation has been disabled. Contact your…

Error message

Package installation has been disabled. Contact your administrator for more information.

What it means

PluginEnvironmentError::PackageInstallationDisabled is thrown when a package installation is requested while package installation has been administratively disabled in the plugin environment configuration. The fixed message instructs contacting the administrator.

Solutions

  1. Ask the administrator to enable package installation or to pre-install the required packages
  2. Declare the plugin's dependencies at deploy time (baked image / pre-built venv) instead of runtime install
  3. Use an allowlisted plugin bundle that already contains its dependencies
  4. Check the processing engine configuration for the package-install flag before shipping the plugin

Example fix

# before (disabled)
# processing_engine.package_install = false
# after (admin enabled, or pre-install)
# processing_engine.package_install = true
/path/venv/bin/pip install influxdb3_client requests
Defensive patterns

Strategy: validation

Validate before calling

# confirm installs are allowed before requesting a package install
allowed=$(tomlq -r '.processing_engine.package_install // false' influxdb3.conf)
[ "$allowed" = "true" ] || { echo 'package installation disabled; contact admin'; exit 1; }

Try / catch

match env_manager.install_package(plugin, pkg).await {
    Err(PluginEnvironmentError::PackageInstallationDisabled) => {
        eprintln!("installation disabled by policy; using pre-provisioned environment");
        Err(anyhow!("package install blocked by admin policy"))
    }
    other => other,
}

Prevention

When it happens

Trigger: A plugin (or operator action) attempts to install a Python package into the plugin environment while the server config sets installation disabled (e.g. plugin package-install off).

Common situations: Hardened production deployments where admins forbid runtime package installs for supply-chain security; a plugin declaring new dependencies is deployed to such an instance; tenants request packages the operator has not allowlisted.

Related errors


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

Appendix: source

Thrown at influxdb3_processing_engine/src/environment.rs:28

use std::sync::{Arc, OnceLock};
use thiserror::Error;

#[derive(Error, Debug)]
pub enum PluginEnvironmentError {
    #[error("Package manager not available: {0}")]
    PackageManagerNotFound(String),
    #[error("External call failed: {0}")]
    InstallationFailed(#[from] std::io::Error),
    #[error("Plugin environment management is disabled")]
    PluginEnvironmentDisabled,

    #[error("Virtual environment error: {0}")]
    VenvError(#[from] VenvError),

    #[error("Failed to list packages: {0}")]
    PackageListFailed(String),

    #[error(
        "Package installation has been disabled. Contact your administrator for more information."
    )]
    PackageInstallationDisabled,
}

pub trait PythonEnvironmentManager: Debug + Send + Sync + 'static {
    fn init_pyenv(
        &self,
        plugin_dir: Option<&Path>,
        virtual_env_location: Option<&PathBuf>,
    ) -> Result<(), PluginEnvironmentError>;
    fn install_packages(&self, packages: Vec<String>) -> Result<(), PluginEnvironmentError>;

    fn install_requirements(&self, requirements_path: String)
    -> Result<(), PluginEnvironmentError>;
}

#[derive(Debug, Copy, Clone)]

View on GitHub (pinned to 06200ef96b)