{"record":{"id":"874b7680c6027ddd","repo":"invoke-ai/InvokeAI","slug":"user-account-is-inactive-or-does-not-exist","errorCode":null,"errorMessage":"User account is inactive or does not exist","messagePattern":"User account is inactive or does not exist","errorType":"http","errorClass":"HTTPException","httpStatus":401,"severity":"error","filePath":"invokeai/app/api/auth_dependencies.py","lineNumber":144,"sourceCode":"            detail=\"Missing authentication credentials\",\n            headers={\"WWW-Authenticate\": \"Bearer\"},\n        )\n\n    token = credentials.credentials\n    token_data = verify_token(token)\n\n    if token_data is None:\n        raise HTTPException(\n            status_code=status.HTTP_401_UNAUTHORIZED,\n            detail=\"Invalid or expired authentication token\",\n            headers={\"WWW-Authenticate\": \"Bearer\"},\n        )\n\n    # Verify the token still grants access: user exists, is active, epoch is current.\n    user = resolve_authorized_user(token_data)\n\n    if user is None:\n        raise HTTPException(\n            status_code=status.HTTP_401_UNAUTHORIZED,\n            detail=\"User account is inactive or does not exist\",\n            headers={\"WWW-Authenticate\": \"Bearer\"},\n        )\n\n    return _db_derived_token_data(token_data, user)\n\n\ndef get_current_user_or_default(\n    credentials: Annotated[HTTPAuthorizationCredentials | None, Depends(security)],\n) -> TokenData:\n    \"\"\"Get current authenticated user from Bearer token, or return a default system user if not authenticated.\n\n    This dependency is useful for endpoints that should work in both single-user and multiuser modes.\n\n    When multiuser mode is disabled (default), this always returns a system user with admin privileges,\n    allowing unrestricted access to all operations.\n","sourceCodeStart":126,"sourceCodeEnd":162,"githubUrl":"https://github.com/invoke-ai/InvokeAI/blob/0b6a024f2ff6a86bfb953dcdb9cc504ef7397a06/invokeai/app/api/auth_dependencies.py#L126-L162","documentation":"For the VP-SDE path, the scheduler builds betas from beta_schedule; only 'linear', 'scaled_linear', and the cosine schedule are implemented. Any other beta_schedule string hits the else branch raising NotImplementedError.","triggerScenarios":"ERSDEScheduler(beta_schedule='squaredcos_cap_v2', ...) or 'quadratic'/'sigmoid' — names valid in other diffusers schedulers but not handled here; also scheduler configs copied verbatim from DDIM/DDPM presets.","commonSituations":"Porting a scheduler config from diffusers where beta_schedule names differ, typos like 'scaled-linear', or new model cards listing beta schedules this port hasn't implemented.","solutions":["Use one of the implemented schedules: 'linear', 'scaled_linear', or the cosine schedule ('cosine')","Rename the config value, e.g. diffusers' 'squaredcos_cap_v2' -> cosine path used here","Subclass the scheduler and add the desired beta schedule to the if/elif chain","Pass precomputed trained_betas directly instead of a named schedule"],"exampleFix":"// before\nsched = ERSDEScheduler(beta_schedule=\"squaredcos_cap_v2\")\n// after\nsched = ERSDEScheduler(beta_schedule=\"linear\")  # or pass trained_betas=[...]","handlingStrategy":"validation","validationCode":"assert beta_schedule in (\"linear\", \"scaled_linear\", \"cosine\"), beta_schedule","typeGuard":"def is_supported_beta_schedule(bs) -> bool:\n    return bs in (\"linear\", \"scaled_linear\", \"cosine\")","tryCatchPattern":"try:\n    sched = ERSDEScheduler(beta_schedule=bs)\nexcept NotImplementedError as e:\n    if \"beta_schedule\" in str(e):\n        sched = ERSDEScheduler(beta_schedule=\"linear\")\n    else:\n        raise","preventionTips":["Translate diffusers beta_schedule names to this scheduler's supported set","Prefer passing trained_betas for exotic schedules","Keep scheduler presets audited against supported schedules"],"tags":["scheduler","not-implemented","config-validation","diffusion"],"backgroundTag":"unsupported-scheduler-config","analyzedSha":"0b6a024f2ff6a86bfb953dcdb9cc504ef7397a06","analyzedAt":"2026-08-29T04:46:49.967Z","schemaVersion":2},"datasetVersion":"2026-08-29T07:17:48.351Z"}