{"record":{"id":"1be4863f6bfbfb84","repo":"NousResearch/hermes-agent","slug":"invalid-pet-slug","errorCode":null,"errorMessage":"invalid pet slug","messagePattern":"invalid pet slug","errorType":"validation","errorClass":"PetStoreError","httpStatus":null,"severity":"error","filePath":"agent/pet/store.py","lineNumber":163,"sourceCode":"        pet = load_pet(configured_slug.strip())\n        if pet and pet.exists:\n            return pet\n    pets = installed_pets()\n    return pets[0] if pets else None\n\n\ndef install_pet(slug: str, *, force: bool = False, timeout: float = _DOWNLOAD_TIMEOUT) -> InstalledPet:\n    \"\"\"Download *slug* from the manifest into the pets directory.\n\n    Idempotent: a fully-installed pet is returned as-is unless *force*.  Raises\n    :class:`PetStoreError` / :class:`~agent.pet.manifest.ManifestError` on\n    failure.\n    \"\"\"\n    from agent.pet.manifest import find_entry\n\n    slug = _safe_slug(slug)\n    if not slug:\n        raise PetStoreError(\"invalid pet slug\")\n    existing = load_pet(slug)\n    if existing and existing.exists and not force:\n        return existing\n\n    entry = find_entry(slug, timeout=timeout)\n    if entry is None:\n        raise PetStoreError(f\"pet '{slug}' is not in the petdex manifest\")\n\n    # Host-pin every asset URL to petdex. The manifest is trusted (HTTPS from\n    # petdex.dev), but pin the asset hosts too so a compromised/spoofed manifest\n    # can't redirect the download at an arbitrary host. Matches thumbnail_png.\n    if not _is_petdex_host(entry.spritesheet_url):\n        raise PetStoreError(f\"refusing non-petdex spritesheet host for '{slug}'\")\n\n    directory = pets_dir() / slug\n    directory.mkdir(parents=True, exist_ok=True)\n\n    sprite_ext = \".png\" if entry.spritesheet_url.lower().split(\"?\")[0].endswith(\".png\") else \".webp\"","sourceCodeStart":145,"sourceCodeEnd":181,"githubUrl":"https://github.com/NousResearch/hermes-agent/blob/c896c09c42910c584c4c7d2325b58c14713ea42c/agent/pet/store.py#L145-L181","documentation":"Error \"invalid pet slug\" thrown in NousResearch/hermes-agent.","triggerScenarios":"Thrown at agent/pet/store.py:163 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Use a pet slug with only allowed characters (lowercase letters, digits, dashes).","Pick the slug from the petdex manifest listing."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"c896c09c42910c584c4c7d2325b58c14713ea42c","analyzedAt":"2026-08-14T17:18:01.089Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}