question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Create Account - Existing username error isn't displayed as expected

See original GitHub issue

Observed behavior

Scenario: Username is already taken - I can fill the same name of already existing username (juan) (Step 1) and I don’t see error message, and I can continue to the next screen with Gender and Birth Year (Step 2) and from there if I click Continue, nothing happens and if I click the browser Back button, just then the error message for already existing username is seen.

Expected behavior

The error message for already existing username is seen on Step 1, after the username field has the same input as an already existing user.

User-facing consequences

On Step 2 screen it is not clear for the user what exactly is happening.

Errors and logs

Steps to reproduce

Preconditions: There must be an already existing account.

  1. Click Create an account button on the login page
  2. On Step 1 page fill the Full name, Username and password field as for Username field use the same input as the one with the already existing account.
  3. Click Continue button
  4. On Step 2 page select Gender and/or Birth year
  5. Click Continue button

Context

Kolibri 0.14.3 OS: Raspbian GNU, Linux 10 Raspberry Pi 4 Chrome (Last version) + FF (Last version)

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:21 (18 by maintainers)

github_iconTop GitHub Comments

1reaction
jonboisercommented, Mar 26, 2021

Sounds like a good plan! I think this new endpoint could be placed in the the core app in this module:

https://github.com/learningequality/kolibri/blob/b49b908d4b22de85234c4e67114626bd4947d6d1/kolibri/core/auth/api_urls.py#L18-L25

When doing this username_exists check, make sure to keep the facility in mind. A Kolibri device can have multiple facilities in it, and it is okay for different facilities to have usernames in common.

So if I try to create an account in Facility A with username user_1, I should not get blocked if Facility B already has that username reserved.

1reaction
metodimilevqacommented, Oct 23, 2020

@metodimilevqa , is the juan username the same one you made during the Setup Wizard? It’s a known issue that if you try to create a new user with the superuser’s name, you will not see an error message inside the form.

However, Kolibri should show some kind of full-page error message, instead of nothing happening after you click Continue.

No, “juan” isn’t the username I used during setup. For the setup I used metodimilev 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error 'Duplicate Username' when you create a username
When receiving 'Duplicate Username found' or 'Username already exists' error message, either pick a new username or have the User with the existing...
Read more >
HTTP Status Code for username already exists when ...
The server attempts to create the new account but finds that the username is already taken. What should the most appropriate HTTP status...
Read more >
"Username not found" error message can be misleading
The current "username not found" error message can lead to a confusing scenario for users who's accounts are stuck in account moderation.
Read more >
Is it unsafe to show message that username/account does not ...
According to the OWASP Auth Guidelines, "An application should respond with a generic error message regardless of whether the user ID or ...
Read more >
User Registration Form not working as expected for logged in ...
The feature that allows registering new users by already logged in users was not working because of the bug. It will be fixed...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found