-
Notifications
You must be signed in to change notification settings - Fork 4.4k
🐛 Bug Report: Error 500 using updateEmail
when password is not set cause OAuth2
#4975
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
Comments
I would like to work on this. @stnguyen90 |
Hey, I would like to fix this @gepd @stnguyen90 |
@gepd, would you please provide the docker logs for the appwrite container related to this error? |
Sure! @stnguyen90 I have updated the issue with the info |
@gepd thanks! let me check with the team to see how we want Appwrite to behave for this. |
I didn't realize, this is caused for a different reason in my case; the user is using an OAuth2 authentication that is why there is not password set. Isn't possible to this happen with email and password authentication as, for use any of that endpoint first you need to have an active session and as the user haven't a password, the session can't be created I think this problem can happen with any other password less authentication method when the user doesn't have set a password |
updateEmail|updatePhone
when password is not setupdateEmail
when password is not set cause OAuth2
@stnguyen90 did you get any answer from the team? |
@gepd, sorry I missed this! we discussed this internally, and we have decided we:
|
Possibly related: #4990 |
To do this, we should skip the validation in this 3 endpoints appwrite/app/controllers/api/account.php Line 1561 in 8b7dd6e
appwrite/app/controllers/api/account.php Line 1661 in 8b7dd6e
appwrite/app/controllers/api/account.php Line 1605 in 8b7dd6e
I can send a PR to fix this, what do you think? |
@gepd, assigned! |
Uh oh!
There was an error while loading. Please reload this page.
👟 Reproduction steps
updateEmail
orupdatePhone
endpoint👍 Expected behavior
Update the email or phone without ask for a password, or use other method to confirm the changes
👎 Actual Behavior
We get an error
I have test it with
updateEmail
andupdatePhone
but this should happen in any endpoint who requires a passwordthe container logs shows the following error:
🎲 Appwrite version
Version 1.2.x
💻 Operating system
Linux
🧱 Your Environment
No response
👀 Have you spent some time to check if this issue has been raised before?
🏢 Have you read the Code of Conduct?
The text was updated successfully, but these errors were encountered: