{"record":{"id":"6d78b4457be9fd5a","repo":"HKUDS/DeepTutor","slug":"skill-is-not-assigned-to-you","errorCode":null,"errorMessage":"Skill is not assigned to you","messagePattern":"Skill is not assigned to you","errorType":"http","errorClass":"HTTPException","httpStatus":403,"severity":"error","filePath":"deeptutor/api/routers/skills.py","lineNumber":207,"sourceCode":"\n@router.get(\"/{name}\")\nasync def get_skill(name: str) -> dict[str, object]:\n    service = get_skill_service()\n    try:\n        return service.get_detail(name).to_dict()\n    except SkillNotFoundError:\n        # User scope doesn't have it. Fall through to admin-assigned lookup\n        # below, which returns 403 if the user has no grant for it.\n        pass\n    except InvalidSkillNameError as exc:\n        raise HTTPException(status_code=400, detail=str(exc))\n\n    user = get_current_user()\n    if user.is_admin:\n        # Admin scope already checked above; nothing else to look at.\n        raise HTTPException(status_code=404, detail=f\"Skill not found: {name}\")\n    if name not in assigned_skill_ids(user.id):\n        raise HTTPException(status_code=403, detail=\"Skill is not assigned to you\")\n    detail = assigned_skill_detail(name)\n    if detail is None:\n        raise HTTPException(status_code=404, detail=f\"Skill not found: {name}\")\n    return detail\n\n\n@router.post(\"/create\")\nasync def create_skill(payload: CreateSkillRequest) -> dict[str, object]:\n    service = get_skill_service()\n    try:\n        info = service.create(\n            name=payload.name,\n            description=payload.description,\n            content=payload.content,\n            tags=list(payload.tags or []),\n        )\n        return info.to_dict()\n    except SkillExistsError:","sourceCodeStart":189,"sourceCodeEnd":225,"githubUrl":"https://github.com/HKUDS/DeepTutor/blob/3e82f130422a813cdd73c10b21a44e9325f5821a/deeptutor/api/routers/skills.py#L189-L225","documentation":"Error \"Skill is not assigned to you\" thrown in HKUDS/DeepTutor.","triggerScenarios":"Thrown at deeptutor/api/routers/skills.py:207 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"3e82f130422a813cdd73c10b21a44e9325f5821a","analyzedAt":"2026-08-27T06:57:25.364Z","schemaVersion":2},"datasetVersion":"2026-08-27T08:17:20.692Z"}