All my app webComponents take a lot of time to trigger the gotText logic

Out of nowhere, few days ago, my appinventor web components started to act very differently. It takes literally more than 5minutes before the gotText is triggered to process the result of my calls.

when making the same api calls outside of the app(eg: postman), i get an immediate response so it's definitely not an api problem but rather the web components.

it was all working well before that btw.

I am not using app companion to test. i

am actually building the apk file and use the app on my phone.

did anyone go through something similar?

here is a sample request that i use for you as a reference.

I presume you are using Firebase as your online data store, and you are using Firebase Authentication email/password for your users ?

yes that's correct

Is it just the login causing the problem, or any calls you make to Firebase with the web component ?

Is your device using data connection or wifi ? Are these both stable with good connections ?

Try without the responseCode check, do you get a quicker response ?

it's all calls actually not just the login one. i am using Wifi and it is very stable connection. even without the responseCode check, it is still very very slow unfortunately.

one more thing. i tried to keep clicking on login button with wrong pwd while waiting for the response of the first call.. it takes forever like i said. but once i get a response, it will be all th responses to my clicks.

So it seems as once the first call is responding, the rest of the calls also respond immediately

How are your secure rules setup on Firebase?

It may also be worth setting up a new aia project to test sign up / sign in, may help if this works to show there is something going on in your main app project.

Testing with companion ?

One more thing, have you plenty of space left on your Firebase project, not used up your quotas etc. ?

1 Like

here are some weird findings.

yesterday out of nowhere it started to work back as usual so i didnt bother much investigating it.

However, today the same thing happened again. so i tried t build another app with only webcomponent and got the same issue(very very slow response of gotText that can take up to 5 minutes).. i tried even using a different firebase account with rules set to true for both read and right and again the issue persisted.

at this point i really dont understand what is happening. and again if i make the api call anywhere outside of the app(like Postman) it works perfectly fine.

Did you try the above ( I guess you are not strictly testing the responseCode in postman...)

yes without the responseCode check and i tested with both companion and also by building the apk file.. same behaviour

Try a test aia using the AI2 firebase component on a project with unsecure rules. (if you are using the us-central server)

Or try with this new extension:

What server are you using for your firebase project?

It seems like a local issue to you, no-one else is reporting an issue, and I have been making calls to firebase today with the web component without any issues.

thanks for the recommendation i guess i will have to change the way i communicate to firebase.. however, can i ask if this extension uses the firebase sdk? or it uses the api in the background?

My guess is it is using the REST api in the background

1 Like

i will ask also just to double check but i think u r right considering the data we get form the response of the requests

You could also try your current web1.gottext like this...


just excludes any other block activity

maaaan i want to cry wright now. i have actually tried different phones, and then i disabled wifi on one of them to use data and it worked, while the one using wifi didnt work(had the latency problem).. i really dont understand why since my wifi is really working fine as i stream music, watch videos and receive notificaitons on my phone without a problem.

I am wondering why it doesnt work. but at least i found a pattern

Something in wifi/router configuration - firewall/DNS/? (partially) blocking AppInventor ?

You could also try running companion via USB, to bypass the wifi, see if that works ? (no extensions though, there is a bug)

when i changed my private DNS settings from "Automatic" to "OFF", it worked.

thanks a lot @TIMAI2 for following up with me through this until we identified the cause. I really appreciate your help. keep up the amazing work you are doing

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.