Page 1 of 1
strange problems : memory and built-in objects
Posted: Wed Aug 07, 2013 7:49 am
by PLUdev
Hi, I need some help about two points please.
1- my software development file ('myApplication'.livecode) doesn't stop increasing in size. I'm sure that this is not due to the number of code lines I have added. My first version is around 32 Mo and now the last version is around 94 Mo ! I am working on Windows 7 and my livecode version is 4.5.3. Have you already faced such a problem ?
2- I have found in my application some 'particular' livecode objects added in a custom card I have created. For example, the group revLibraries.
This causes the error of revLoadLibraries that I have met during code execution on my standalone (the bug report window appears and tells where the issue is). I don't know how these 'particular' livecode objects have been put on my card. When I try to erase them, they are created again automatically. Have you got an idea please?
Nota Bene : When I run my application in the development environment, there is no execution error.
Thx for your support.
Re: strange problems : memory and built-in objects
Posted: Wed Aug 07, 2013 8:51 am
by shaosean
If I am not mistaken, the revLibraries group is to allow your compiled application to load and use the IDE libraries and externals..
Re: strange problems : memory and built-in objects
Posted: Thu Aug 08, 2013 7:50 am
by PLUdev
shaosean wrote:If I am not mistaken, the revLibraries group is to allow your compiled application to load and use the IDE libraries and externals..
Yes, I think your are right. But this group was not on my card initially. So I suppose I made a bad manipulation on the development environment, and I now this group is on my card and brings issues on my standalone application. I believe this is not normal to have a Livecode built-in object which appears on a customer card. So what can I do now ?
Re: strange problems : memory and built-in objects
Posted: Thu Aug 08, 2013 11:06 am
by shaosean
It gets added there during the standalone building process.. Just delete it and the IDE will re-add it when you re-compile..
Re: strange problems : memory and built-in objects
Posted: Fri Aug 09, 2013 8:33 am
by PLUdev
shaosean wrote:It gets added there during the standalone building process.. Just delete it and the IDE will re-add it when you re-compile..
I have performed some tests. I have created a new project with a main stack and a card with a few code lines. I have built the standalone. I don't see any built-in object (whose name begins with 'rev') added on my card. I have displayed invisible objects. Still noting. I have played with the IDE option to display all the livecode built-in objects on the application browser ('engine' libraries...). No issue to go back after that. Still nothing on my card.
So I really think this is abnormal to see built-in objects in a custom card (that you have designed)!
On my work application, I believe my situation has become abnormal (bad manipulation, IDE bug ?) and causes pb and I don't know how to go back, because as you said there is no obvious way to delete permanently the built-in objects visible on my custom card.
Re: strange problems : memory and built-in objects
Posted: Fri Aug 09, 2013 11:30 am
by shaosean
You would normally not see it in the IDE, as it only gets copied over during the standalone building process.. The private command revCopyScriptLibraries in the sub-stack revSaveAsStandalone of stack revStandaloneSettings is where to look..
Re: strange problems : memory and built-in objects
Posted: Fri Aug 09, 2013 1:09 pm
by Klaus
Hi PLUdev,
1. no idea what makes your stack increase in size that much, but that are surely
NOT some lines of code that Livecode will add!
But images, videos and audio clips will!
2. What is the script that causes the error you experience in your standalone?
Or what is the error at all? I'm sure we can sort it out!
Best
Klaus
P.S.
Will move this thread, this anything but OFF-TOPIC!

Re: strange problems : memory and built-in objects
Posted: Fri Aug 09, 2013 6:22 pm
by jacque
Just to clarify, the rev library is added to your standalone when the executable is built so that any rev-specific commands in the scripts will work. It is not added to your working stack, which is why you don't see it in the IDE. The library is already part of the IDE and doesn't need to be added to your working stack during development. Without the IDE present, your standalone does need those libraries. It is correct behavior to have nothing to delete on any of the cards in the stack.
The rev libraries are nowhere near that big, so I agree with Klaus that something else is causing the size creep. Do as Klaus suggests and tell us the actual error message you are getting and whether your stack works with media and images. I'm pretty sure the error isn't related to the size issue though, it's most likely a separate problem.
Re: strange problems : memory and built-in objects
Posted: Mon Aug 12, 2013 12:46 pm
by PLUdev
Hi,
1- my application is connected to a MS Access database ; and I use imported images (objects) but very few. And it's the case since the beginning of the development, so there is no reason to see the size of the livecode project go on increasing like that ! No obvious explanations. And when I use bigger images, there are stored in the disk and not imported as livecode objects.
2- There are on my custom card called "Vue" these rev objects for example :
button revCommon
btn revDatabase
btn revTable
btn rev
grp revLibraries (which behaves like a background) : the one which causes issue in my standalone (see the bug report at the end)
The script where there is the execution error is working with the card "Vue" : the most significative lines are below :
put the script of cd "Vue" of stack "B" into temp
delete cd "vue" of stack "B"
copy cd "vue" of stack "Sauvegarde" to stack "B"
set the script of cd "Vue" of stack "B" to temp
Nota Bene: strangely, the execution error always happens at the second time the script is executed.
Anyway, my wish is not to modify the code if possible. But i think the real solution is to find the way to erase permanently these rev objects on my custom card.
*** FIND HERE THE bug report :
Executing at 1:44:30 PM on Wednesday, July 24, 2013
Type: Object Name:
Object: group "revLibraries" of card "Vue" of stack "C:/Atelier Essai/Essai/20130710_Test Exe V26/test exe 4/Essai_IHM.exe"
Line: revLoadLibraries
Line Num: 0
Hint: revLoadLibraries
Re: strange problems : memory and built-in objects
Posted: Mon Aug 12, 2013 6:49 pm
by jacque
I'm still confused about the setup. I think this is what you are saying:
1. Your working stack has no rev objects
2. Your standalone does have rev objects
3. The error occurs only in the standalone
Is that right? If so, the first two things are normal and expected. The third thing, the error, would occur if you are copying the card before the stack is fully loaded, like in a preOpenStack or preOpenCard handler. The rev libraries are not loaded yet and will error. Copying the card later in the message sequence solves that problem.
It's important to know that standalones cannot save themselves, so the replacement card will not be there the next time the app launches. Maybe you already know that.
If you are saying the rev objects are in your working stack, before you have made a standalone, then that is not at all normal and I've never heard of it happening. But you also said you couldn't find them in your stack, so I don't think that's what happened.
I'm still confused. Can you clarify?
Re: strange problems : memory and built-in objects
Posted: Wed Aug 14, 2013 12:42 pm
by PLUdev
Hi Jacque,
I clarify the setup :
1. "Your working stack has no rev objects" : no : my working stack HAS rev objects (i.e. in my file .livecode): I am sure also that this is not normal and is probably the cause of the execution error
2. "Your standalone does have rev objects" : I suppose but I don't know (how to check outside the IDE ?)
3. "The error occurs only in the standalone" : true
Thx for your support
Re: strange problems : memory and built-in objects
Posted: Wed Aug 14, 2013 7:11 pm
by jacque
I don't think the rev libraries are in your stack, not only because you can't find them, but because the error you posted indicates they can't be found.
The error looks like the rev libraries did not get included in your standalone. The command "revLoadLibraries" failed, and that could be because it can't find the handlers it needs. I think the problem is that the libaries are missing from your standalone, not that they are wrongly in your stack.
In standalone settings, do you have any libraries selected for inclusion? Are you using automatic inclusions, or are you selecting them individually? If you are using automatic, try turning that off and select only the libraries your app actually needs. Then rebuild the standalone and see what happens.