Page 1 of 2

Can't save stack issue

Posted: Wed May 09, 2018 9:47 pm
by dunbarx
This started when I upgraded from v.6 to v.8, months ago.

Every so often, a stack I am working on will fail to save, I get a dialog telling me so, and the reason being that it "cannot open stack file". I dismiss the dialog, and nothing changes, except no save.

The first couple of times I lost all my work with a forced quit. Then I tried saving the stack with another name via "Save as...". That worked fine, and I just renamed the new stack file. Then I got really smart and simply saved it with the same name, whereupon I was asked if I wanted to replace the original. I said "OK", it did its thing, and all is good.

Anyone see this?

Craig Newman

Re: Can't save stack issue

Posted: Tue May 15, 2018 1:10 am
by MaxV

Re: Can't save stack issue

Posted: Tue May 15, 2018 2:46 pm
by dunbarx
Max.

Thanks.

But this still leaves the issue: "What is going on", or, as I am fond of saying, "What am I doing wrong", or, as I am even fonder of saying, "Why me?"

Craig

Re: Can't save stack issue

Posted: Tue May 15, 2018 2:49 pm
by bogs
dunbarx wrote:
Tue May 15, 2018 2:46 pm
...or, as I am even fonder of saying, "Why me?"
If not you, then I :wink:

Re: Can't save stack issue

Posted: Tue May 15, 2018 4:38 pm
by jacque
Did you move the stack in the Finder while it was open? It sounds like the filename is no longer accurate when it fails to save.

Re: Can't save stack issue

Posted: Tue May 15, 2018 6:02 pm
by dunbarx
Jacque.
Did you move the stack in the Finder while it was open?
Nope.

On this project I am always working on a stack who's stack file sits on the desktop. That was a sensible observation, though.

This only started happening a few months ago. I have been fooling around with this stack for two years. I am not sure it has anything to do with migrating to v.8.

Craig

Re: Can't save stack issue

Posted: Tue May 15, 2018 10:46 pm
by jacque
Maybe insert "answer the filename of this stack" before saving and see if anything changed behind your back.

Re: Can't save stack issue

Posted: Wed Jul 25, 2018 5:38 pm
by dunbarx
Jacque.

Well.

This is what the "fileName of this stack" gives normally.
/Users/craignewman/Desktop/ledWorker356.livecode
And this is what I get, per your astute suggestion, when I cannot save any longer, and before I have to "Save as", with the same name, and agree to replace the existing stack.
/Users/craignewman/Desktop/LEDSplash356/MacOSX/LEDSplash356.app/Contents/MacOS/ledWorker356.livecode
In all instances, the stack file is on the desktop along with the stack itself, and so is the splash stack and its file that I use to make standalones. So all four are on the desktop, always, and about every 20th time I try to save the main working stack, I get the dialog that LC "cannot open stack file".

The workaround has never failed, but it makes me nervous. The long pathname above points to the most recent copy of the standalone executable ("LEDSplash356"), located in its own folder on the desktop. When I make a standalone, I place it in that folder along with its earlier cousins. In that folder is a windows version as well, since everyone that uses this runs windows. But it is the Mac "app" that seems to be insinuating itself into play.

Craig

Re: Can't save stack issue

Posted: Wed Jul 25, 2018 9:54 pm
by jacque
Yes, it does seem to be finding the embedded copy in the app instead of the working copy on the desktop. I don't have an explanation for that, unless for some reason you opened the embedded copy by accident. Is there a reason to embed a copy of the stack? Maybe taking it out would fix things.

That doesn't explain why LC switched its default folder to inside the app bundle though. That appears to be what it's doing.

Re: Can't save stack issue

Posted: Wed Jul 25, 2018 11:00 pm
by dunbarx
Jacque.

How could it decide to go into the app just now and then? I am not really expecting an answer, only laying out the situation. I do not ever access the app in that folder while I am fooling around with the stack. It just does it haphazardly.

I cannot reproduce, and I doubt that the stack is at fault. If nobody else has ever seen this, I will live with it.

Craig

Re: Can't save stack issue

Posted: Thu Jul 26, 2018 5:50 pm
by jacque
Does the error only happen after you've built a standalone and before you've reopened the independent stack? LC does close and reopen stacks after a build. If your build process includes the problem stack then its new file path could be the filename.

Re: Can't save stack issue

Posted: Sun Jul 29, 2018 10:15 pm
by dunbarx
Jacque.
Does the error only happen after you've built a standalone and before you've reopened the independent stack?
No, I make standalones, each uniquely numbered, for this internal app regularly, as either bugs are found or features added. I keep a copy of all versions in a folder on my desktop. I will eventually start working on a new variant. The most recent standalone build is safely in its folder, perhaps having been made days before. The working mainstack is open from the desktop.

Most times, since I save often, I never see the dialog. But now and then I do, and it is always in the middle of a working session. I will "save as", using the proffered (identical) stack name, take the suggestion to replace, and all is well. Thereafter I can always save in the ordinary way.

I just have the feeling I am skirting some sort of corruption, since nobody else seems ever to have seen this.

Again, I cannot reproduce the process; it happens randomly. I have not simply tried to repeatedly save the mainstack until it happens. Maybe I will try that for several minutes. In that case I could send the most recent standalone build along with the mainstack and see what they say.

Craig

Re: Can't save stack issue

Posted: Tue Jul 31, 2018 11:26 pm
by karmacomposer
I've not had this issue on the Windows version. Saves are fine.

Mike

Re: Can't save stack issue

Posted: Wed Dec 13, 2023 3:07 pm
by CAsba
Hi,
I've got the same problem. So, I 'save as' to desktop, before close down. Before start up, I copy the desktop file to the LC defined path,
C:\program files\runrev\livecode 9.6.11.
Then I select the LC path file in the start centre. A bit of a chore, but functional...

Re: Can't save stack issue

Posted: Wed Dec 13, 2023 3:37 pm
by Klaus
Hi CAsba,

a "regular" user has no permission to save files in the "programm files" folder!
(Same on macOS with the "Applications" folder)
Create a folder somewhere else on your hd to save your projects in!


Best

Klaus