Significant-Gravitas/AutoGPT · warning · NotFoundError

Store listing version {store_listing_version_id} not found

Error message

Store listing version {store_listing_version_id} not found

What it means

NotFoundError raised by get_available_graph when no StoreListingVersion row matches the id AND isAvailable=true AND isDeleted=false, or the row exists but its AgentGraph relation is missing. It means the requested listing version is not publicly installable.

Source

Thrown at autogpt_platform/backend/backend/api/features/store/db.py:378

async def get_available_graph(
    store_listing_version_id: str,
    hide_nodes: bool = True,
) -> GraphModelWithoutNodes | GraphModel:
    try:
        # Get avaialble, non-deleted store listing version
        store_listing_version = (
            await prisma.models.StoreListingVersion.prisma().find_first(
                where={
                    "id": store_listing_version_id,
                    "isAvailable": True,
                    "isDeleted": False,
                },
                include={"AgentGraph": {"include": AGENT_GRAPH_INCLUDE}},
            )
        )

        if not store_listing_version or not store_listing_version.AgentGraph:
            raise NotFoundError(
                f"Store listing version {store_listing_version_id} not found",
            )

        return (GraphModelWithoutNodes if hide_nodes else GraphModel).from_db(
            store_listing_version.AgentGraph
        )

    except Exception as e:
        logger.error(f"Error getting agent: {e}")
        raise DatabaseError("Failed to fetch agent") from e


async def get_store_agent_by_version_id(
    store_listing_version_id: str,
) -> store_model.StoreAgentDetails:
    """Get agent details from the StoreAgent view (APPROVED agents only).

    See also: `get_store_agent_details_as_admin()` which bypasses the

View on GitHub (pinned to 9c8bb5550f)

Solutions

  1. Refresh the store listing to obtain the current store_listing_version_id and retry.
  2. If you own the listing, check its moderation/availability state (isAvailable/isDeleted) in the creator dashboard.
  3. Remove or refresh cached version IDs in the client instead of persisting them long-term.
  4. Handle 404 with a user-facing 'this agent is no longer available' state.

Example fix

// before — cached version id from an old page
await addAgent(cachedVersionId);
// after — always resolve the current listing first
const listing = await getAgentDetails(username, slug);
await addAgent(listing.listing_version_id);
Defensive patterns

Strategy: validation

Validate before calling

// Resolve the CURRENT version id before installing
const details = await getStoreAgentDetails(username, slug);
if (!details?.listing_version_id) throw new Error('no available version');
await addAgentFromStore(details.listing_version_id);

Type guard

function isAvailableListing(v: { isAvailable?: boolean; isDeleted?: boolean }): boolean {
  return v.isAvailable === true && v.isDeleted !== true;
}

Try / catch

try { return await getAvailableGraph(versionId); }
catch (e) {
  if (isNotFound(e)) { toast('This agent is no longer available'); return null; }
  throw e;
}

Prevention

When it happens

Trigger: Requesting a graph by store_listing_version_id that is misspelled, belongs to a version that was taken down (isAvailable=false), was soft-deleted, or whose parent graph was removed. Adding an agent from a stale store page whose version was superseded/unpublished also hits it.

Common situations: User keeps an old store page open and clicks 'add' after the version was unpublished; concurrent moderation taking a listing down mid-session; frontend caching version IDs past their validity; deleted test listings still referenced by bookmarks.

Related errors


AI-assisted analysis of Significant-Gravitas/AutoGPT@9c8bb5550f (2026-08-14). Data as JSON: /api/errors/dbb3c9151ab33d8d. Report an issue: GitHub.