"The following objects were modified outside the script editor, would you like to reload them"

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

danielrr
Posts: 140
Joined: Mon Mar 04, 2013 4:03 pm

"The following objects were modified outside the script editor, would you like to reload them"

Post by danielrr » Sun May 12, 2019 2:26 pm

Whenever I use a specific stack, I keep receiving the following warning:

"The following objects were modified outside the script editor, would you like to reload them"

It appears every time I try to save a script, or while I am scripting, for no reason I can isolate. Its becoming really annoying. :shock:

Somebody knows why this may happen, and how to get rid of it?

I am using dropbox, but I don't have this issue with any other stack I usually use from Dropbox.

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by bogs » Sun May 12, 2019 3:12 pm

I've seen this pop up on the forum before, so maybe reading that will help you isolate the cause.

The only thing I am pretty sure of is that you will see that message if you or a script is editing the control script outside of the SE. Since your indicating this is happening with one stack in particular, maybe go through the code and see if it is triggering a change to some object.
Image

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9801
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by FourthWorld » Sun May 12, 2019 3:21 pm

How do you respond to the prompt?
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

danielrr
Posts: 140
Joined: Mon Mar 04, 2013 4:03 pm

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by danielrr » Sun May 12, 2019 3:51 pm

I tryed both ways, "cancel" and "Reload". ANd the problem remains the same, only that if you answer "reload" there's some panick since all the script vanishes the very second (it reappears latter)

danielrr
Posts: 140
Joined: Mon Mar 04, 2013 4:03 pm

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by danielrr » Sun May 12, 2019 3:54 pm

The only odd thing I see is that, if I go to the Proyect browser of this particular stack, in addition to all the cards I can see a "Data Grid Templates" (followed by a longish number) I can't say anything bout.
bogs wrote:
Sun May 12, 2019 3:12 pm
I've seen this pop up on the forum before, so maybe reading that will help you isolate the cause.

The only thing I am pretty sure of is that you will see that message if you or a script is editing the control script outside of the SE. Since your indicating this is happening with one stack in particular, maybe go through the code and see if it is triggering a change to some object.

Klaus
Posts: 13793
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by Klaus » Sun May 12, 2019 4:12 pm

danielrr wrote:
Sun May 12, 2019 3:54 pm
... in addition to all the cards I can see a "Data Grid Templates" (followed by a longish number) I can't say anything bout.
LC will create this automatically when you add a Datagrid to your stack, so this is desired behavior!

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7210
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by jacque » Sun May 12, 2019 4:35 pm

LiveCode tracks the last version of the script it knows about and if it differs from the current one, you get that dialog. That's because LC allows you to use an external script editor and it wants to be sure you meant to keep the changes the external editor made. But there's a glitch somewhere that triggers the dialog even when you don't use an external editor, and I've seen the same thing you do occasionally. I've never figured out why.

If any of your other controls are changing the script, that may cause it. Or if you paste in a revised script or handler, that might too, though I've done that a lot and never got the dialog. Do you have any scripts that set the script of a different control? I wonder if the datagrid does that.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

danielrr
Posts: 140
Joined: Mon Mar 04, 2013 4:03 pm

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by danielrr » Mon May 13, 2019 2:52 pm

Thanks Jacque,

There's nothing special in this stack. No calls to an external editor (I'd like to know how can I call an external editor, BTW) no weird things. Just ordinary do this and that via functions stuff. All non-basic fields, erased. I tried (twice) to start anew: I created a new stack. Created fresh new buttons & copied the script from the old buttons into the new buttons (even copy&pasting via BBedit to delete all weid stuff and evil spirits)… and the problem remains the same. It is really annoying not only because I need to answer the unsolicited messages (about 20 times an hour) but because eventually LC crashes. I feel miserable :cry:

bogs
Posts: 5435
Joined: Sat Feb 25, 2017 10:45 pm

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by bogs » Mon May 13, 2019 7:58 pm

danielrr wrote:
Mon May 13, 2019 2:52 pm
No calls to an external editor (I'd like to know how can I call an external editor, BTW)
In the olden days of Mc, circa 2.5, you could call an external editor directly from the preferences by entering the cli for the editor of choice, which was subsequently hidden when it went OSS, but here is what it looked like...
Preferences_001.png
Edit from outside of yourself...
Sometime there-after, Ken Ray (I think) created a plugin to achieve the same thing, named the STS/MLXEditor...
STS-MLXEditor 2.0.1_002.png
STS/MLX-pealidocious!
Which you can still download from his site: http://www.sonsothunder.com/devres/live ... nloads.htm

However, I won't be able to vouch for whether it works or not in the newest versions of Lc, as I rarely venture past 6.x. I believe it was still working as of 7.x though :roll:

You will give up some things using an external editor, proper syntax coloring (unless it is atom, sublime, or a few others), and of course debugging is a bit more extended and the like.
Image

danielrr
Posts: 140
Joined: Mon Mar 04, 2013 4:03 pm

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by danielrr » Thu May 16, 2019 3:54 pm

I have identified a piece of code that causes LC keep asking me to reload the script again and again with the infamous prompt "The following objects were modified outside the script editor, would you like to reload them", until it eventually crashes. BUt the thing is, it is not the code itself (it is just a declaration) but some hidden character what is causing the problem. I am sending the characters using an attachment, just for the curious of you. Can anybody do something with this info?
Attachments
bugLC.livecode.zip
(982 Bytes) Downloaded 201 times

Fjord
Posts: 132
Joined: Sat Dec 06, 2008 6:18 pm
Location: France

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by Fjord » Sun Aug 15, 2021 5:19 pm

Just got that same message again:
- 1) each time I save a script, I get, first the 'Saving…' message, all right, then the "The following objects were modified outside the script editor, would you like to reload them" dialog, where I choose 'Cancel'
and
- 2) whenever I change app then go back to Livecode
These happen all the time BUT for one of my stacks, that does NOT trigger that message :!: :?:

A first class pain in the neck. That is the reason I could never finish a reasonably-sized, long term, project for several years (I even went as far as giving Javascript a try…). Year after year, I start developing again, then get the problem, then out of frustration drop Livecode entirely for several months/years, then give it another try without a problem… only for a few weeks.

Could it be related to my using a French version of the system (Big Sur)?
Now the real question is: how do I stop this? Wipe out the system and reload it?
--
François

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9567
Joined: Wed May 06, 2009 2:28 pm
Location: New York, NY

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by dunbarx » Sun Aug 15, 2021 8:50 pm

I see this, but only now and then, as well. Try this. On a card with a field and two buttons named "b1" and "b2", I placed this in the script of btn b1:

Code: Select all

on mouseUp
   put random(99) into fld 1
end mouseUp
and this in the script of bin "b2":

Code: Select all

on mouseUp
   get the script of btn "b1" 
   put "9" after char 16 of line 2 of it
   set the script of btn "b1" to it
end mouseUp
Now when I click on b1, I get random numbers less than 100 all day. If I then click on b2, and then back on b1, I get random numbers less than 1000 all day. And so on...

But if I then try to edit the script of b2, I get the dialog. Odd, because it is the script of b1, not b2, that has been "modified outside the script editor."

This is repeatable. But in any case this anomaly is nowhere near as annoying to me as the OP seems to feel. Perhaps he sees it much more often than I do?

Craig

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3975
Joined: Sun Jan 07, 2007 9:12 pm
Location: Bochum, Germany

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by bn » Mon Aug 16, 2021 8:53 am

@danielrr

In your sample stack it looks a lot like this bug

https://quality.livecode.com/show_bug.cgi?id=23295

and is is caused by 2 byte characters

In your case it is character ó that causes the reload problem. If I remove that character from the script everything is fine.

You might want to add a comment to that bug report.

Kind regards
Bernd

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3975
Joined: Sun Jan 07, 2007 9:12 pm
Location: Bochum, Germany

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by bn » Mon Aug 16, 2021 10:02 am

@François

could you test your stack's scripts for 2 byte character like in é. But é comes in two varieties: as an UTF-8 é and an ASCII é. And it is the UTF-8 é that causes the problem, see bug report linked to below.

Maybe you also should add a comment to
https://quality.livecode.com/show_bug.cgi?id=23295

Kind regards
Bernd

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3975
Joined: Sun Jan 07, 2007 9:12 pm
Location: Bochum, Germany

Re: "The following objects were modified outside the script editor, would you like to reload them"

Post by bn » Mon Aug 16, 2021 12:32 pm

To test if your script contains 2-byte characters you could paste your script into a field and then make a button with the following code

Code: Select all

on mouseUp
   local tText, tMultiCodePoints
   put field 1 into tText
   repeat for each char aChar in tText
      if the number of codePoints of aChar > 1 then 
         put aChar & cr after tMultiCodePoints
      end if
   end repeat
   if tMultiCodePoints is empty then
      put "no multi-codepoints chars found"
   else
      put tMultiCodePoints
   end if
end mouseUp
If one or more 2 byte characters are found then they will be listed in the message box, otherwise the message "no multi-codepoints chars found" will be shown.

Kind regards
Bernd

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”