I’m sure you have address this, but I found that when my app had ANYin the app to the deleteAllMarkers (depricated) performance was awful. When I removed that call, performance for ALL map functions improved. I have NO IDEA why, just an observation.
Hi @drted, I deleted the “deleteAllMarkers” block in my example app, but the performance was still awful. It still took approx. 8 seconds to display 20 (new) markers.
@Steven: I installed a system monitoring tool on Android. I found out that under normal circumstances 3…4 CPUs run with full power, the other 4…5 with slower frequencies. BUT when I call the “map” component all CPUs run with full speed during the mentioned 8 seconds, and after that the markers get displayed. So there must be something going on during the delay, I think this is insinde thunkable’s machine.
Yeah, it seems like it is just very computationally expensive in the current implementation. I’m looking into other possible solutions that might reduce the burden. I don’t think the Data Viewer directly contributes to the problem but it does cause rerenders and the DV generally is more difficult to render than other components. Under the hood it is just a group of components but obviously rendered a few times (depending on the amount of data in your data source) and it has to go fetch the data to populate those rows. So my guess would be you might see similar results if you had a screen with enough components but no Data Viewer.
Anyway, I’m hoping we can just refactor the way that markers are added to reduce the computational load. I don’t know how long this would take so I can’t promise any timeline. If this is a major blocking point for your app, feel free to share it with me privately and we can explore potential temporary workarounds for you.
Hi @jared,
the problems show up when using map component and a data viewer (list/grid) and a local data source, even when the block “addMarkers” does not use the local data source. For me this constellation of componentes looks rather familiar.
Feel free to have a look at my example app: when switching to the map it generates 20 markers at random positions. On my iPhone7 / iOS14.01 it takes approx. 8 seconds to display the markers. Remix the app, test this on your phone. Then, delete the local data source and test the time again. Now it should take less than a second to show the markers:
If I made a mistake please tell me so. Right now I am not able to finish a new release of an app so I need help really urgent.
@jared In addition to what @Michael_Rogulla said, it is possible that some hardware would be fast enough for users not to notice any slow down.
…and it depends on how many markers get added. I got the impression that the delay is directly related to the number of markers (but not the number of entries in the data viewer list!).
So, strange update. Before, my markers were showing as in the video. today when i run the app without any changes other than updating to ios 14 from 13.7, the marker display is slow as heck now!
Hm that is odd. Are you talking about a built app that you’re running or our Thunkable Live app? Do you know if you updated the Thunkable Live app recently? I have a couple ideas that I’m exploring now as to how we can speed the process up but it is possible that I’ve misidentified the issue and it is caused by some library update or iOS update.
Has anyone seen this same issue on Android or is it only iOS at the moment?
Also, can someone who is experiencing the problem confirm if you see the same issue when inserting a large number of polylines/polygons into a map?
In my experience the speed decrease is not only related to the maps component. I found that a simple loop to create 4 buttons took approx. 20 seconds on my iPhone 6S. This used to works much faster some months ago, even with this old iPhone. I suspect changes in underlying libraries (memory management? event handling?).
Thanks for following up. That is interesting, I haven’t heard of general slowness until now so it is possible that something that was recently changed caused unintended slow downs. I’ll have to dig deeper into this and see if we can determine the cause.
I have some changes in testing now which will improve the performance around creating/cloning components (including map markers) though it currently isn’t clear if this change will return the performance to previous levels. I expect the change should be available by early next week (I’ll follow up here to let you know when exactly). Afterwards, I’ll rely on anyone who was experiencing the issue to confirm whether any further optimizations are needed.
My experience with this issue was not as severe as the reports here. As such, though the improvements have greatly reduced the issue that I was seeing, I can’t be certain it will be sufficient for the issues you all have seen. I’m hoping that it is but if not, I’ll take another look and see what else we can improve upon.
Thanks for communicating the changes! Knowing is half the battle.
My change should be available now. Please update your Thunkable Live app and let me know if you see any improvements. I’ll keep an eye on the responses in case I need to take another look at it.
Hi @Steven,
On Android: Live app 24102: my apps with maps and data viewer list now run very well. I’ll keep on testing further but right now it seems to be allright.
On iOS: Live app 241-01 (no update in App store): a simple app with map and data viewer works very well now. But two real life apps (with more complex structures) are hanging. The apps start, they show some parts of the first screen, but not even the loading icon, which is used in the app, starts spinning. I think I’ll wait until the version 241-02 will be available on iOS.
I haven’t tested downloads yet.
BTW: it seems that my apps are sorted differently now in Thunkable live: the most recent apps are now at the top of the list. Great, thanks! Is there any way to disable the upper part “Tutorials”, so that I can see even more of my current apps?
@Michael_Rogulla Please consider adding a like/comment to this GitHub issue I created: https://github.com/thunkable/thunkable-issues/issues/707
Hi @tatiang, I totally agree with you!
I’ve been following this post. I was having general slowness but didn’t think my slowness was related. But things are moving much quicker for me now which is making my process so much more efficient! Thank you!
@Michael_Rogulla let me know once the iOS update is available. If they are still slow after the update I can take another look. Are they similarly set up? Where you would assume the slowness is caused by a loop creating components or map markers?
@tatiang Thanks for sharing the issues repo, it is super helpful to keep the discussion in one place! I’ll follow up with you there with a quick question on your request.