Back

Flutter SDK webApp AppwriteException response null

  • 0
  • Flutter
Darthbert
5 Sep, 2023, 01:19

Greetings, I am testing the account api inside a flutter web app and an android app. When I try to create a user with an existing email, i get an AppwriteException (correct behaviour). Problem is the only field populated in the exception is message, and all the other fields are null. Exception The message is an html string that shows the correct code and error message (409, A user with the same id, email, or phone already exists in this project)

I am using the latest flutter, appwrite sdk, and appwrite server

My understanding of the documentation is I should get a fully populated AppwriteException as per client_mixin.dart line 73.

TL;DR
The user is encountering an issue with the Flutter SDK and AppwriteException while testing the account API in a Flutter web app and an Android app. The problem is that when trying to create a user with an existing email, they receive an AppwriteException, but only the message field is populated, while all other fields are null. The message shows the correct code and error message. The user is using the latest Flutter, Appwrite SDK, and Appwrite server. They mention that according to the documentation, they should receive a fully populated AppwriteException. No solution is given in the support thread.
Drake
5 Sep, 2023, 02:53

That is weird...what version of Appwrite?

Darthbert
5 Sep, 2023, 02:54

Appwrite 1.4.1, sdk 9 and 10

Drake
5 Sep, 2023, 02:54

Interesting...I'll need to test this.

Drake
5 Sep, 2023, 18:49

That's weird..it seems to work for me:

Drake
5 Sep, 2023, 18:50

are you able to check the request headers in the browser network logs?

Drake
5 Sep, 2023, 18:51

is that domain you're using the main domain (_APP_DOMAIN) or a custom domain?

Darthbert
5 Sep, 2023, 19:59

A custom domain.

Darthbert
5 Sep, 2023, 20:00

I'll check the headers when I get in in a couple of hours

Drake
5 Sep, 2023, 21:34

ah i was able to reproduce with a custom domain

Drake
5 Sep, 2023, 21:34

would you be able to create an issue?

Darthbert
5 Sep, 2023, 21:50

Sure!

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more