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

Frontend crashes when new project modal is opened. #4172

Open
bohemiancode-x opened this issue Oct 16, 2024 · 4 comments
Open

Frontend crashes when new project modal is opened. #4172

bohemiancode-x opened this issue Oct 16, 2024 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@bohemiancode-x
Copy link

Pulled the latest update from the main branch and the app crashes when I try to open the get started modal (that has starter projects). On further inspection, I found out the /flows/basic_examples endpoint returns an html page that is stored as in the examples store and triggers the typeError (examples.find() is not a funtion.)
Screenshot 2024-10-16 at 12 12 03 PM

Copy link

dosubot bot commented Oct 16, 2024

The error you're encountering, "TypeError: examples.find is not a function," suggests that the examples state is not being set as an array, which is required for the find method to work. This issue arises because the /flows/basic_examples endpoint is returning an HTML page instead of the expected JSON data.

To resolve this, you should check why the endpoint is returning an HTML page. This could be due to a misconfiguration in the backend or an issue with the request being made to the endpoint. Ensure that the endpoint is correctly set up to return JSON data and that the request is properly formatted.

Additionally, verify that the frontend code handling the response from this endpoint includes error handling to manage unexpected data types. This can prevent the application from crashing when the response is not as expected.

To continue talking to Dosu, mention @dosu.

@dosubot dosubot bot added the bug Something isn't working label Oct 16, 2024
@anovazzi1
Copy link
Contributor

hey just tested the main branch and I couldn't reproduce, can you check again?

@bohemiancode-x
Copy link
Author

hey just tested the main branch and I couldn't reproduce, can you check again?

I'm still facing this issue. The /flows/basic_examples endpoint returns an html template which makes the examples.find() function throw an error. Is there a way to troubleshoot the api response? I either run the backend with docker or through the terminal with "langflow run"

@anovazzi1
Copy link
Contributor

anovazzi1 commented Oct 25, 2024

Hey @bohemiancode-x, unfortunately I can't reproduce the bug, but I notice you are running on port 3001 and based with the endpoint response probably you have a problem related to your setup, can you double check the backend and the frontend are running properly in the right ports? how are you running the langflow?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants