Significant-Gravitas/AutoGPT · error · NotFoundError
Failed to update library agent for {agent_graph_id} v{agent_
Error message
Failed to update library agent for {agent_graph_id} v{agent_graph_version} What it means
Error "Failed to update library agent for {agent_graph_id} v{agent_graph_version}" thrown in Significant-Gravitas/AutoGPT.
Source
Thrown at autogpt_platform/backend/backend/api/features/library/db.py:792
)
lib = await prisma.models.LibraryAgent.prisma(tx).update(
where={"id": library_agent.id},
data={
"AgentGraph": {
"connect": {
"graphVersionId": {
"id": agent_graph_id,
"version": agent_graph_version,
}
},
},
},
include={"AgentGraph": True},
)
if lib is None:
raise NotFoundError(
f"Failed to update library agent for {agent_graph_id} v{agent_graph_version}"
)
schedule_info = await _fetch_schedule_info(user_id, graph_id=agent_graph_id)
return library_model.LibraryAgent.from_db(lib, schedule_info=schedule_info)
async def create_graph_in_library(
graph: graph_db.Graph,
user_id: str,
folder_id: str | None = None,
is_hidden: bool = False,
) -> tuple[graph_db.GraphModel, library_model.LibraryAgent]:
"""Create a new graph and add it to the user's library."""
graph.version = 1
graph_model = graph_db.make_graph_model(graph, user_id)
graph_model.reassign_ids(user_id=user_id, reassign_graph_id=True)
View on GitHub (pinned to 9c8bb5550f)
Solutions
- Retry the update; check server logs for the underlying database error.
- Verify the graph ID and version still exist.
When it happens
Trigger: Thrown at autogpt_platform/backend/backend/api/features/library/db.py:792 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of Significant-Gravitas/AutoGPT@9c8bb5550f (2026-08-14).
Data as JSON: /api/errors/8d200720b1be4188.
Report an issue: GitHub.