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

Cannot convert a user to admin role if they existed as chat user (usually with some non-default auth) #1609

Closed
sadda11asm opened this issue Feb 18, 2022 · 2 comments · Fixed by botpress/botpress#11679, botpress/botpress#11709 or botpress/botpress#11769
Labels
bug Something isn't working

Comments

@sadda11asm
Copy link

Describe the bug
The bug has different use cases where it happens:
The first is when the user has talked to the bot and authenticated with SSO, and then they cannot be added as an admin. The error shows the user exists.
The second is when the user was an admin and also a chat user, and they cannot access the privileges of admin because Botpress thinks they are chat users. (Usually when in the database the chat user entity goes before the admin entity)

To Reproduce
Steps to reproduce the behavior:

  1. Have SSO set up for the users
  2. Talk to the bot firstly
  3. Try to add the user with that email as an admin
  4. See an error that user exists, but not listed with other users/admins

Expected behavior
Chat user entity should be ignored when adding a user as an admin. And when logging in to the system, the entity of admin should be taken instead of chat user

Screenshots
If applicable, add screenshots to help explain your problem.

Environment (please complete the following information):

  • Server is hosted, Database used is Postgres

Additional context
Add any other context about the problem here.

@laurentlp
Copy link

For anyone having this issue, you simply need to specify at least one authentication strategy in your workspace definition (workspaces.json). You will then have access to a list of users that are configured on those strategies.

@github-actions
Copy link

github-actions bot commented Apr 26, 2022

Available on v12.27.0

@botpress botpress deleted a comment from github-actions bot Apr 26, 2022
@michaelmass michaelmass transferred this issue from botpress/botpress Jun 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment