tchapgouv / tchap-android

A matrix client for Android.
https://play.google.com/store/apps/details?id=fr.gouv.tchap.a
Apache License 2.0
19 stars 7 forks source link

Error 500 when inviting external email in a DM #856

Closed appndigital closed 1 year ago

appndigital commented 1 year ago

When using the external email invitation, the Room is created but stays empty. The webservice createRoom send back an 500 error when posting a third party email

In order to reproduce, go to home -> Kebab menu -> Invite to join -> put email address and validate

odelcroi commented 1 year ago

can be related : https://app.crisp.chat/website/6dacc68e-de3a-4511-8177-1339616098de/inbox/session_02424b61-e093-424e-9125-f64f4e4219f3/

odelcroi commented 1 year ago

https://app.crisp.chat/website/6dacc68e-de3a-4511-8177-1339616098de/inbox/session_c128a2d2-0d17-423b-8906-41826928e760/

odelcroi commented 1 year ago

@giomfo @yostyle the invititationby email invitation to a (new) external user to a DM seems to be broken

jdauphant commented 1 year ago

It's 2.7.0 or before ?

jdauphant commented 1 year ago

Apparently it's the case from Support

giomfo commented 1 year ago

@giomfo @yostyle the invititationby email invitation to a (new) external user to a DM seems to be broken

I will have a look on this

giomfo commented 1 year ago

I believed that this error was due to a problem server side, but I succeeded to invite an external email account from Tchap-iOS, so this is an actual issue in Tchap-Android I investigated the request built client side during this invite, I failed to find what is wrong. I will check with Ops the logs server side to have more information on this 500 Internal Server Error

giomfo commented 1 year ago

@appndigital Can you please try to reproduce on your side this issue (FYI I reproduced in Prod)

giomfo commented 1 year ago

According to my last investigation, the error happened server side when the server tries to invite the email in the created DM. The error means the id_access_token provided by the Tchap-Android client is not correct. This token is one of the Invite3pid parameters:

image

@NicolasBuquet @appndigital :

NicolasBuquet commented 1 year ago

Fix removed by #949

jdauphant commented 1 year ago

Il faudra corriger les erreurs en base de données une fois le correctif en prod.