Clone component working slow?

Does anyone else is experiencing that the clone component is working too slow?

when I want to clone something is taking too long to do it and is wasn’t like that before specially when I edit some of the components inside the clone retrieving information from objects it takes more time

It’s running slower than we’d like. I’m working to change how we interpret the blocks to speed it up, but it might take a while to fix.

4 Likes

Glad to hear this is being worked on. It’s such a powerful block and it would be great to have it optimized for speed.

1 Like

Hey @paulmw, it appears that since recently, something changed and now cloning on Android is slow AF using the same projects it used to work decently on (but never as fast as on iOS). On iOS it still works fine, it is only Android that now has the issue. Did you change anything on the back end?

Thanks
K

1 Like

You are right, in the latest version of Live, one component is cloned on Android for 1 second. Previously the same component was cloned at a rate of 10 components per second

Not just the Live, but the compiled app as well… this needs to be fixed pronto! @paulmw

@paulmw Problem fix ! is very fast now thank you =D

The problem is solved, but the statement that it started working very fast is too strong a word.

It’s back to what it used to be. A completely unrelated change to the system caused it to slow down, but that got fixed. Some of our other speed improvements will hopefully be rolling out soon (particularly on block dragging speed). It’ll be a while before I finish changing the evaluation speed for blocks like the clone block (I’ve identified the problem, but the fix is complicated).

2 Likes

@paulmw I want to give a big thanks to you and the the rest of the @thunkable team for working hard to keep this an accessible platform for programmers of any skill level!

An app I build a few weeks ago would clone 25 buttons in about two seconds when downloaded and run on an iPhone 8. I just tried it again, without making changes to the project, and it took about six seconds and didn’t clone everything properly. So I’m not sure what to make of that.

But @actech is right… even at the previous speed of 10 components per second, it’s quite slow. Comparable tools can clone components at a rate of at least 30 components per second. So I’m hopeful they continue to improve the cloning process.

1 Like

I’m working on an app now with a page that uses cloning.

When the app initially opens and the page displays, it loads in under 10 seconds consistently. However, if I go to another screen in the app and then come back, the same page will take 70 - 90 seconds to load.

Any logical explanation for this from the technical side?

is it going to be a tutorial coming up Darren?

Does returning to the first page trigger the creation of more clones in addition to the ones created when first opening that page?

No, for this test case I am loading the same record with no changes.

Also the screen is not in a navigator, so it does not “stay awake”. Each time I navigate to it, it is starting fresh.

It may not be staying awake but it may be opening new pages instead of returning to the previous ones hence using up more and more memory which in turn leads to the slowness. My understanding is that not using a navigator is the same as using the stack navigator which, as I have mentioned before, is an accident waiting to happen. For example, when you navigate from page A to B and back to A, you have 3 screens in memory, not 1. This is the huge disadvantage with the stack (or no) navigator.

1 Like