Old Model uses Extension API 4.1 and wont open

52 views
Skip to first unread message

Eric Carley

unread,
Oct 10, 2021, 10:09:15 PM10/10/21
to netlogo-users
This is a newbie question for sure, but I have had no luck in my searches.  I am getting the following error when I try to open the Supply Chain model by Alvaro Gil.
"Warning:  You are attempting to open a NetLogo extension file that was created fora different version of the NetLogo Extension API.  (This NetLogo uses Extension 4.1;the extension uses NetLogo Extension API 5.0.)  NetLogo can try to load the extension, but it might not work. "

Yup ... it doesn't work.  I have both NetLogo 6.2 and 4.1.3 installed.  I try loading the v2 or v3 of the step-by-step models http://agiltools.com/Resources/Supply_Chain_Step_by_Step.zip
and they cannot load and crashes with Java errors.

Can someone explain what this error is and how I can resolve it?  I also have the latest version of MatLab running on my computer.  All of this  is in Windows Pro 10.

Any ideas would be great ... and very much appreciated after hours of hitting my head on this problem I have a migraine :D:D:D
Many thanks folks!
-Eric

Dale Frakes

unread,
Oct 10, 2021, 11:11:42 PM10/10/21
to netlog...@googlegroups.com
Eric,

I'm assuming you're working with this model: http://modelingcommons.org/browse/one_model/3378#model_tabs_browse_nlw

When I download it, I actually get a warning while unzipping it (failed CRC check), and it looks like the .nlogo file, at least, is partially corrupted.  When I tried to open in in Netlogo 6.0.2, it says "Expected nlogo file to have 12 sections, this had 11."

When I open it in Netlogo 5.3.1, it opens just fine and seems to work.  When I resave that out, a key difference seems to be the very last line:



The final section marker in the original file seems to be cut short.

So then I opened the original file in Netlogo 5.3.1, then saved it.  This seemed to fix the missing section marker and made a few trivial changes in the numbers of spaces on some of the lines.

I then opened that "corrected" file in Netlogo 6.0.2... it goes through a conversion process, but both models seem to work in their respective versions of Netlogo.

That said, by "work", I mean that there don't seem to be any bugs that prevent the models from running in Netlogo.  That doesn't mean they're doing what they're supposed to. 

I've attached both here.

Cheers!

Dale
--
You received this message because you are subscribed to the Google Groups "netlogo-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to netlogo-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/netlogo-users/2534f8bc-b2eb-4c3a-9616-57151abe35d5n%40googlegroups.com.

-- 
Dale Frakes
Adjunct Instructor, PhD Candidate
PSU Systems Science
dfr...@pdx.edu - http://web.pdx.edu/~dfrakes/
Supply_Chain_v5.nlogo
Supply_Chain_v6.nlogo

Eric Carley

unread,
Oct 12, 2021, 10:40:27 AM10/12/21
to netlogo-users
Thank You Dale!
Quick feedback on the Zip ... many of these models are compressed using a WinRAR zip, so you have to use 7-Zip to extract the files without error.  With respect to the models, I am using http://modelingcommons.org/browse/one_model/3378#model_tabs_browse_discuss and specifically the step-by-step models in this zip file:  http://agiltools.com/Resources/Supply_Chain_Step_by_Step.zip
Models v2 and v3 give the API Extension error.  It looks like I have to recreate the models manually to get them to work, otherwise, the API conflicts just crash upon running.
Best Wishes! -Eric
Reply all
Reply to author
Forward
0 new messages