{"record":{"id":"4bf9e67c6cce0ba8","repo":"Pumpkin-MC/Pumpkin","slug":"license-was-revoked-or-refunded-0","errorCode":null,"errorMessage":"License was revoked or refunded: {0}","messagePattern":"License was revoked or refunded: (.+?)","errorType":"exception","errorClass":"LicenseError","httpStatus":null,"severity":"error","filePath":"crates/pumpkin-plugin-utils/src/license.rs","lineNumber":24,"sourceCode":"};\nuse std::{\n    path::{Path, PathBuf},\n    time::{Duration, SystemTime, UNIX_EPOCH},\n};\nuse thiserror::Error;\nuse tracing::{debug, info};\n\n/// License checking and verification errors.\n#[derive(Debug, Error)]\npub enum LicenseError {\n    /// HTTP communication error with marketplace.\n    #[error(\"Marketplace HTTP error: {0}\")]\n    Http(#[from] HttpError),\n    /// Metadata validation error (e.g. missing license on paid plugin).\n    #[error(\"License metadata mismatch: {0}\")]\n    MetadataMismatch(String),\n    /// License revoked or refunded by marketplace.\n    #[error(\"License was revoked or refunded: {0}\")]\n    Revoked(String),\n    /// License is expired.\n    #[error(\"License has expired on {0}\")]\n    Expired(String),\n    /// I/O error reading/writing license cache.\n    #[error(\"I/O error with license storage: {0}\")]\n    Io(#[from] std::io::Error),\n    /// JSON serialization error.\n    #[error(\"JSON serialization error: {0}\")]\n    Json(#[from] serde_json::Error),\n    /// Plugin is unsigned or missing marketplace metadata.\n    #[error(\"Plugin is unsigned or missing marketplace metadata\")]\n    UnsignedPlugin,\n    /// Plugin has not been initialized.\n    #[error(\n        \"Plugin-utils has not been initialized (call pumpkin_plugin_utils::init(context) first)\"\n    )]\n    NotInitialized,","sourceCodeStart":6,"sourceCodeEnd":42,"githubUrl":"https://github.com/Pumpkin-MC/Pumpkin/blob/8d4639e25a57c15e47448ec327c780d41bbf2356/crates/pumpkin-plugin-utils/src/license.rs#L6-L42","documentation":"LicenseError::Revoked means the marketplace reports the plugin's license as revoked or refunded, so the plugin is no longer licensed to run. The license string/identifier is included via {0}. This is a definitive licensing decision from the server, not a transient failure.","triggerScenarios":"License verification against the marketplace returns a revoked/refunded status for the plugin's license; occurs on initial check and on periodic re-validation or offline-grace expiry followed by re-check.","commonSituations":"User requested a refund on the marketplace; license was revoked for terms-of-service violations; license transferred to another account/server; shared license key used beyond its entitlement.","solutions":["Purchase a new/valid license for the plugin on the marketplace.","Verify you are using the correct license key/account (transfers may have moved it).","Contact marketplace support if the revocation appears erroneous.","Remove or disable the plugin if no valid license is obtained.","Check the marketplace account email for refund/revocation notices."],"exampleFix":"// before\nlet license = manager.verify()?; // fails with Revoked\n// after\nmatch manager.verify() {\n    Ok(l) => enable_plugin(l),\n    Err(LicenseError::Revoked(id)) => {\n        tracing::error!(\"license {id} revoked — disable paid features\");\n        disable_paid_features();\n    }\n    Err(e) => return Err(e.into()),\n}","handlingStrategy":"try-catch","validationCode":null,"typeGuard":"fn is_revoked(e: &LicenseError) -> bool {\n    matches!(e, LicenseError::Revoked(_))\n}","tryCatchPattern":"match manager.verify() {\n    Ok(l) => activate(l),\n    Err(LicenseError::Revoked(id)) => {\n        tracing::error!(\"license {id} revoked/refunded — disabling plugin\");\n        disable_plugin();\n    }\n    Err(e) => return Err(e.into()),\n}","preventionTips":["Keep the marketplace subscription/payment method current.","Watch for refund/revocation emails from the marketplace.","Don't share license keys across servers beyond entitlement.","Periodically re-verify to detect revocation promptly."],"tags":["license","marketplace","compliance"],"backgroundTag":"license-revoked","analyzedSha":"8d4639e25a57c15e47448ec327c780d41bbf2356","analyzedAt":"2026-09-09T15:32:22.916Z","contentChangedAt":"2026-09-09T15:32:22.916Z","schemaVersion":2},"datasetVersion":"2026-09-16T04:17:20.429Z"}