{"record":{"id":"b924830c64fb0c11","repo":"hasura/graphql-engine","slug":"authconfig-v3-is-deprecated-please-consider-upgra","errorCode":null,"errorMessage":"AuthConfig v3 is deprecated. Please consider upgrading to AuthConfig v4.","messagePattern":"AuthConfig v3 is deprecated\\. Please consider upgrading to AuthConfig v4\\.","errorType":"error_code","errorClass":"Warning","httpStatus":null,"severity":"warning","filePath":"v3/crates/auth/hasura-authn/src/lib.rs","lineNumber":268,"sourceCode":"                }\n            ),\n            jsonpath::JSONPath::new(),\n        )\n        .unwrap()\n    }\n}\n\n/// Warnings for the user raised during auth config generation\n/// These are things that don't break the build, but may do so in future\n#[derive(Debug, PartialEq, thiserror::Error)]\npub enum Warning {\n    #[error(\n        \"AuthConfig v1 is deprecated. `allowRoleEmulationBy` has been removed. Please consider upgrading to AuthConfig v4.\"\n    )]\n    PleaseUpgradeV1ToV4,\n    #[error(\"AuthConfig v2 is deprecated. Please consider upgrading to AuthConfig v4.\")]\n    PleaseUpgradeV2ToV4,\n    #[error(\"AuthConfig v3 is deprecated. Please consider upgrading to AuthConfig v4.\")]\n    PleaseUpgradeV3ToV4,\n    #[error(\"Header '{0}', used in the auth config, is not a valid header name\")]\n    InvalidHeaderName(String),\n    #[error(\"Header value '{0}' is not a valid header value for header '{1}' in the auth config\")]\n    InvalidHeaderValue(String, String),\n}\n\nimpl Warning {\n    pub fn should_be_an_error(&self, flags: &open_dds::flags::OpenDdFlags) -> bool {\n        match self {\n            Warning::InvalidHeaderName(_) | Warning::InvalidHeaderValue(_, _) => {\n                flags.contains(open_dds::flags::Flag::DisallowInvalidHeadersInAuthConfig)\n            }\n            _ => false,\n        }\n    }\n}\n","sourceCodeStart":250,"sourceCodeEnd":286,"githubUrl":"https://github.com/hasura/graphql-engine/blob/724551b9ae87845594ef0408cff0e50eb6c90dc5/v3/crates/auth/hasura-authn/src/lib.rs#L250-L286","documentation":"A warning emitted during auth config generation when the metadata declares AuthConfig v3. v3 still builds but is deprecated and will be removed; upgrading to v4 is recommended.","triggerScenarios":"Auth config generation encounters an AuthConfig with version: 3 in the OpenDD metadata.","commonSituations":"Recently upgraded projects whose auth metadata was authored for the previous major release (v3) and has not yet been migrated.","solutions":["Migrate the auth config from v3 to v4 using the metadata migration tooling","Review the v3→v4 changelog for behavioral differences (e.g. role emulation removal) before upgrading","Rebuild and confirm no deprecation warnings remain"],"exampleFix":"// before\nauthConfig: { version: 3 }\n// after\nauthConfig: { version: 4 }","handlingStrategy":"validation","validationCode":"if auth_config.version != 4 {\n    eprintln!(\"warning: AuthConfig v{} is deprecated; upgrade to v4\", auth_config.version);\n}","typeGuard":"fn isSupportedAuthConfig(v: u32) -> bool { v == 4 }","tryCatchPattern":"match build_auth_config(&metadata) {\n    Err(e) if e.to_string().contains(\"AuthConfig v3 is deprecated\") => plan_migration(e),\n    r => r,\n}","preventionTips":["Migrate v3 configs before the next engine upgrade","Verify migrated config behavior in staging","Enable warnings-as-errors in CI to force timely migration"],"tags":["auth","deprecation","auth-config","migration"],"backgroundTag":"deprecated-api-version","analyzedSha":"724551b9ae87845594ef0408cff0e50eb6c90dc5","analyzedAt":"2026-08-28T07:32:55.105Z","schemaVersion":2},"datasetVersion":"2026-08-28T11:17:15.048Z"}