langflow-ai / langflow

⛓️ Langflow is a visual framework for building multi-agent and RAG applications. It's open-source, Python-powered, fully customizable, model and vector store agnostic.

Home Page:http://www.langflow.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CommandError: Multiple head revisions are present for given argument 'head'; please specify a specific target revision, '<branchname>@head' to narrow to a specific head, or 'heads' for all heads

nguyenlykhanhlinh opened this issue · comments

Describe the bug
I encountered a bug when I installed using the following command:
python -m pip install langflow==0.6.19 --force-reinstall
And I encountered an error as in the picture, how can I fix this error?

Browser and Version

  • Browser [chrome]
  • Version [Langflow==0.6.19]

Screenshots
image
image

To fix the error related to multiple head revisions in Alembic when running Langflow, you need to merge the multiple heads. Here are the steps to resolve this issue:

  1. Identify the current heads:

    alembic heads
  2. Merge the heads:

    alembic merge <head1> <head2> -m "merge heads"

Replace <head1> and <head2> with the actual revision IDs of the heads you want to merge. This will create a new migration script that merges the multiple heads into a single head, resolving the conflict.

Additionally, ensure that Alembic is properly initialized and configured in your Langflow setup. You can refer to the DatabaseService class in src/backend/base/langflow/services/database/service.py for methods like init_alembic and run_migrations to handle Alembic initialization and migrations [1][2].

To continue talking to Dosu, mention @dosu.

Are you getting the same with latest 1.0.5?