Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: set folder id on flows imported on startup #4018

Merged
merged 6 commits into from
Oct 4, 2024

Conversation

jordanrfrazier
Copy link
Collaborator

Using LANGFLOW_LOAD_FLOWS_PATH to import flows on startup did not set the folder_id correctly, causing flows to be orphaned in the frontend, with no way to display them. The api/v1/flows still lists them, which is why it originally was considered working.

This PR adds folder_id to both existing orphaned flows and newly created flows.

Note that the current behavior just uses the default_folder as the folder. Ideally, as per #4010, we'd have the ability to scope flows to folders and users. This PR is the first step so as to unblock users from the basic functionality.

@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. bug Something isn't working labels Oct 4, 2024
@github-actions github-actions bot added bug Something isn't working and removed bug Something isn't working labels Oct 4, 2024
Copy link

This pull request is automatically being deployed by Amplify Hosting (learn more).

Access this pull request here: https://pr-4018.dmtpw4p5recq1.amplifyapp.com

src/backend/base/langflow/initial_setup/setup.py Outdated Show resolved Hide resolved
src/backend/base/langflow/initial_setup/setup.py Outdated Show resolved Hide resolved
src/backend/base/langflow/initial_setup/setup.py Outdated Show resolved Hide resolved
src/backend/base/langflow/initial_setup/setup.py Outdated Show resolved Hide resolved
Copy link
Contributor

@ogabrielluiz ogabrielluiz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Oct 4, 2024
@jordanrfrazier jordanrfrazier enabled auto-merge (squash) October 4, 2024 17:13
@jordanrfrazier jordanrfrazier merged commit 7fe478e into main Oct 4, 2024
34 of 35 checks passed
@jordanrfrazier jordanrfrazier deleted the 4010-fix-load-paths-env-var branch October 4, 2024 17:19
diogocabral pushed a commit to headlinevc/langflow that referenced this pull request Nov 26, 2024
* set folder id on flows imported on startup
---------

Co-authored-by: Gabriel Luiz Freitas Almeida <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working lgtm This PR has been approved by a maintainer size:M This PR changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants