Open apppbuilder opened 2 weeks ago
This issue is stale because it has been open for 7 days with no activity. If there are no further updates, a team member will close the issue.
Do not close this issue. Thank you. @ignalauret
Hey @apppbuilder thanks for your report. Our technical team has been checking your issue and they said this is not a bug. Apparently the Custom Function test mode doesn't support what you are trying to achieve. In their words:
"This is not a bug. It is a known limitation in custom code. Firestore calls does not work in functions test mode as it does not compile the entire app code.".
So sadly, you are going to have to test them on the Run modes. I will create a feature request to enable this testing, but I don't know when that can get implemented. I'm sorry for the inconvenience, have a great day!
@ignalauret Well... thank you for your reply, but to be honest it's not in the test mode... it's in the real version of the app after deployed. I'll check again and see if it's corrected or not...
Soon I'll be back with more data.
Ok, let's go to real data. @ignalauret
Here is a live app, deployed and in closed testing inside an android smartphone.
The flow is an "on page load" and after calling an API Call that triggers a Cloud Function, it returns some userData to make the app move further.
=========================
=========================
I used some "Update App State" to check when it was stopping in the live app.
=========================
Results: It stopped in the action before deconding data... (erroState now equals 6)
=========================
Results: = The same... It stopped in the action before deconding data... (erroState now equals 6)
=========================
So, to make this happen, I removed the phraseRaf field that was returning from the Cloud Function and also created a new DataType inside Flutterflow:
Results: = Now it works perfectly. I printed the image when it turned "7", just to see if it really got through, the rest are simple actions to change the loading screen and it also worked...
=========================
Has your issue been reported?
Current Behavior
JSON data is not being decoded to DataType when it contains a Document Refence.
Expected Behavior
It should decode everything and return dataType.
Steps to Reproduce
Also, I tried decoding the data with the JSON to DataType and it didn't worked, that's why I got in the Custom Function to check what would be happening.
Reproducible from Blank
Bug Report Code (Required)
IT4gz8rlvJR2rsRE+ZSIbu9ammYUNkN9Rpc0stluZxEoIpznBuw+e8nBdlBWTsjiaVNcfWaWhnkzptLyj9jPOuw7Ay2bG9w/+JZcTjnOe2ijabq0O5aoeEcmI+RXfHKA1sOW3QlSC/hfSGAF12eUPtmiZATDBOu/Zwh9f6PHaOI=
Context
I'm receiving data from Cloud Function POST API, so I need to decode it and start using it. Everything is ok with the Cloud Function, it's sending data and everything, but the data is not showing properly in the app, after lots of tests, found it that it was in the DocReference item.
Visual documentation
Additional Info
I created an isolated project to check if the problem would persist, and yes, it keeps up.
Also, if you all wanna see the isolated project and check everything, I'll send a bug report code below:
IT4gz8rlvJR2rsRE+ZSIbu9ammYUNkN9Rpc0stluZxEoIpznBuw+e8nBdlBWTsjiaVNcfWaWhnkzptLyj9jPOuw7Ay2bG9w/+JZcTjnOe2ijabq0O5aoeEcmI+RXfHKA1sOW3QlSC/hfSGAF12eUPtmiZATDBOu/Zwh9f6PHaOI=
(the problem isn't in the widget, but in the custom functions while decoding the data)
Environment
General
Relative to the time the changes were made, data was lost within
When following my steps to reproduce, data loss happens