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

v1.0.15 - Not able to Sign Up new users #3313

Closed
codenprogressive opened this issue Aug 13, 2024 · 9 comments
Closed

v1.0.15 - Not able to Sign Up new users #3313

codenprogressive opened this issue Aug 13, 2024 · 9 comments
Labels
bug Something isn't working

Comments

@codenprogressive
Copy link

Bug Description

I'm disabling Auto_login and setting up superuser.

LANGFLOW_AUTO_LOGIN=false
LANGFLOW_SUPERUSER="admin"
LANGFLOW_SUPERUSER_PASSWORD="dummypasword"
LANGFLOW_NEW_USER_IS_ACTIVE=false
LANGFLOW_SECRET_KEY="randomly_generated_secure_key"

when a new user is trying to sign up, an error will pop up (see screenshot)

image

Reproduction

  1. pip install langflow==1.0.15
  2. python -m langflow run --env-file ./env
  3. on the login screen, click on sign up

Expected behavior

new user is supposed to be successfully signed up, and admin should be able to receive the new user form to activate it.

Who can help?

No response

Operating System

Ubuntu

Langflow Version

1.0.15

Python Version

3.10

Screenshot

No response

Flow File

No response

@codenprogressive codenprogressive added the bug Something isn't working label Aug 13, 2024
Copy link

dosubot bot commented Aug 13, 2024

The "Method Not Allowed" error during user sign-up could be due to middleware blocking the sign-up endpoint when LANGFLOW_AUTO_LOGIN is set to false. Specifically, the ApiInterceptor function includes a response interceptor that checks for 401 and 403 status codes and might reject the request if autoLogin is false [1].

Additionally, ensure that the environment variables are correctly set and passed to the langflow run command. Here are the key environment variables you need:

  1. LANGFLOW_AUTO_LOGIN: Set to False.

    export LANGFLOW_AUTO_LOGIN=False
  2. LANGFLOW_SUPERUSER and LANGFLOW_SUPERUSER_PASSWORD: Set these for the superuser.

    export LANGFLOW_SUPERUSER=admin
    export LANGFLOW_SUPERUSER_PASSWORD=dummypassword
  3. LANGFLOW_SECRET_KEY: A secure, randomly generated string.

    export LANGFLOW_SECRET_KEY=randomly_generated_secure_key
  4. LANGFLOW_NEW_USER_IS_ACTIVE: Set to False if you want new users to be manually activated.

    export LANGFLOW_NEW_USER_IS_ACTIVE=False

Run the application with these environment variables:

langflow run --env-file ./env

If the issue persists, it might be a bug in version 1.0.15. You may want to check for any updates or patches that address this issue.

To continue talking to Dosu, mention @dosu.

@codenprogressive
Copy link
Author

Yes, it's a bug that I start facing in v1.0.15. When I downgrade to v1.0.14, signing Up users works fine!

@codenprogressive codenprogressive changed the title Not able to Sign Up new users v1.0.15 - Not able to Sign Up new users Aug 13, 2024
@codenprogressive
Copy link
Author

Hey @italojohnny any chance you can reproduce the bug? Just wanted to confirm it is not something wrong with my configs!

To the community, anyone else can reproduce this bug in v1.0.15?

@rezpablo
Copy link

I just went through the same problem, it occurred when signing up and also when accessing with admin and creating a new user.

@detodavide
Copy link

detodavide commented Aug 16, 2024

Yes, I have the same problem, and even with the latest version I can't log in using the login feature, while with version 1.0.14 I don't have these problems using the same .env.

ENV:
LANGFLOW_DATABASE_URL=postgresql://langflow:langflow@langflow_db:5432/langflow
DO_NOT_TRACK=true
LANGFLOW_AUTO_LOGIN=false
LANGFLOW_SUPERUSER="admin"
LANGFLOW_SUPERUSER_PASSWORD="securepassword"
LANGFLOW_SECRET_KEY="eandom_keyss"
AUTH_ACCESS_TOKEN_EXPIRE_MINUTES=-1
AUTH_REFRESH_TOKEN_EXPIRE_DAYS=-1
PYTHONUNBUFFERED=true

To clarify I'm running it on docker.

@codenprogressive
Copy link
Author

@anovazzi1 any chance you can take a look at this issue?

@konradbjk
Copy link

Just leaving my ticket too :D #3438

@Cristhianzl
Copy link
Collaborator

Hi @rezpablo, @codenprogressive, @konradbjk, @detodavide,

Hope you all doing great!

Could you please follow up on PR #3471? This PR should resolve any issues related to login using Langflow on Docker.

The fix will be included in version 1.0.16 of Langflow, so if you're using pip, I recommend waiting for the new release before updating to see if the issue persists. Alternatively, you can fork our main branch and use it locally.

Thank you!

@carlosrcoelho
Copy link
Contributor

#3471

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

7 participants