Hey Seb,

Not well (at all? :P) documented yet but I've recently pushed a debug
mode in the dev branch to avoid dealing with println.

Just run openmole --debug.

Then go to your IntelliJ project and create a remote debug configuration
as shown here that http://stackoverflow.com/a/15505308/470341 (heavily
inspired the solution in the dev branch)

J



On 15/05/17 16:48, reyman wrote:
> After discussion with some developper of Netlogo, two things : 
>
> - the jar on bintray have no extensions
> - extensions are loaded by headless searching into *extensions/*
> folder in the current model directory.
>
> I try to add some println to *Netlogo6Task* to list *files/folders*
> loaded by OpenMOLE with this code in *apply()* method of
> *Netlogo6Task*, but without success :/
>
> /def apply( script: File, launchingCommands: Seq[FromContext[String]],
> embedWorkspace: Boolean = false, seed: OptionalArgument[Val[Int]] =
> None )(implicit name: sourcecode.Name): NetLogo6Task = if
> (embedWorkspace) {
> *println(script.getCanonicalFile.getParentFile.listFiles().mkString("-
> \n")) * workspace(script.getCanonicalFile.getParentFile,
> script.getName, launchingCommands, seed) } else file(script,
> launchingCommands, seed)/
>
> 2017-05-15 16:01 GMT+02:00 reyman <[email protected]
> <mailto:[email protected]>>:
>
>     Hum,
>     It seems there is a method
>     to getExtensionManager(): ExtensionManager
>     
> <http://ccl.northwestern.edu/netlogo/docs/scaladoc/org/nlogo/workspace/ExtensionManager.html>
>  an *ExtensionManager*
>     class available in *HeadlessWorkspace* : 
>
>     
> http://ccl.northwestern.edu/netlogo/docs/scaladoc/org/nlogo/headless/HeadlessWorkspace.html
>     
> <http://ccl.northwestern.edu/netlogo/docs/scaladoc/org/nlogo/headless/HeadlessWorkspace.html>
>
>
>     2017-05-15 15:35 GMT+02:00 reyman <[email protected]
>     <mailto:[email protected]>>:
>
>         The headless API page on github didn't change (
>         https://github.com/NetLogo/NetLogo/wiki/Controlling-API
>         <https://github.com/NetLogo/NetLogo/wiki/Controlling-API> ), i
>         ask directly to dev if something change in headless way to
>         load extensions.   
>
>         2017-05-15 15:26 GMT+02:00 reyman <[email protected]
>         <mailto:[email protected]>>:
>
>             Hi,
>
>             First, there is a change in the path where extension are
>             located in netlogo 6.0.1 official folder >> */app/extensions/*
>             *
>             *
>             In the 6.1 doc, i didn't found any other changes :* *
>             /
>             NetLogo will look for extensions in several places:
>
>             In the folder of the current model.
>             The extensions folder located with the NetLogo
>             installation. For typical NetLogo installations:
>
>             On Mac OS X: /Applications/NetLogo 6.0.1/extensions
>             On 64-bit Windows with 64-bit NetLogo or 32-bit Windows
>             with 32-bit NetLogo: C:\Program Files\NetLogo
>             6.0.1\app\extensions
>             On 64-bit Windows with 32-bit NetLogo: C:\Program Files
>             (x86)\NetLogo 6.0.1\app\extensions
>             On Linux: the app/extensions subdirectory of the NetLogo
>             directory extracted from the installation .tgz
>
>             Each NetLogo extension consists of a folder with the same
>             name as the extension, entirely in lower case. This folder
>             must contain a JAR file with the same name as the folder.
>             For example the sound extension is stored in a folder
>             called sound with a file inside called sound.jar.
>
>             To install a NetLogo extension for use by any model, put
>             the extension's folder in the NetLogo extensions
>             directory. Or, you can just keep the extension's folder in
>             the same folder as the model that uses it./
>
>             2017-05-15 15:18 GMT+02:00 Romain Reuillon
>             <[email protected]
>             <mailto:[email protected]>>:
>
>                 It might be cause by a change in netlogo 6 in the way
>                 it manages extensions in headless. Can you check the
>                 doc of netlogo on this point ? Can you run your model
>                 using the headless mode of netlogo directly?
>
>                 Romain
>
>
>                 Le 15/05/2017 à 15:14, reyman a écrit :
>>                 Hi,
>>
>>                 I'm trying to use a *Netlogo6Task* to run a model
>>                 with *csv* official extensions enabled and rungeKuta
>>                 custom extension i made :
>>                 /
>>                 /
>>                 /extensions [csv rungeKuta]/
>>
>>                 This csv extension exist*by default in 6.1 Netlogo
>>                 folder Netlogo6.0.1/app/extensions. *
>>                 *Run failed with netlogo error which cannot find the
>>                 csv extension.*
>>                 *
>>                 *
>>                 I try to recopy the csv extension which contain the
>>                 jar in my embedeed workdir, also without success.
>>
>>                 Any idea ? 
>>                 /
>>                 /
>>                 /val cmds = List("random-seed ${seed}",
>>                 "setup-openmole 200 ./data/1/ 5", "main-loop")/
>>                 /
>>                 /
>>                 /val micmac = NetLogo6Task( workDirectory /
>>                 "MICMAC-innovativeSHS-v5/MICMAC.nlogo", cmds, true)
>>                  set (...)/
>>
>>
>>                 In the next documentation, it could be cool to add a
>>                 workflow with custom extension.
>>
>>                 Cheers,
>>                 SR.
>>
>>
>>                 -- 
>>                 <http://stackoverflow.com/users/385881/reyman64>
>>
>>
>>                 _______________________________________________
>>                 OpenMOLE-users mailing list
>>                 [email protected]
>>                 <mailto:[email protected]>
>>                 http://fedex.iscpif.fr/mailman/listinfo/openmole-users
>>                 <http://fedex.iscpif.fr/mailman/listinfo/openmole-users>
>
>                 _______________________________________________
>                 OpenMOLE-users mailing list [email protected]
>                 <mailto:[email protected]>
>                 http://fedex.iscpif.fr/mailman/listinfo/openmole-users
>                 <http://fedex.iscpif.fr/mailman/listinfo/openmole-users> 
>
>             -- 
>             <http://stackoverflow.com/users/385881/reyman64>
>
>         -- 
>         <http://stackoverflow.com/users/385881/reyman64>
>
>     -- 
>     <http://stackoverflow.com/users/385881/reyman64>
>
> -- 
> <http://stackoverflow.com/users/385881/reyman64>
>
> _______________________________________________
> OpenMOLE-users mailing list
> [email protected]
> http://fedex.iscpif.fr/mailman/listinfo/openmole-users
-- 
Jonathan Passerat-Palmbach, PhD
Research Associate
Department of Computing
Imperial College London

South Kensington Campus
Huxley Building - room 344
180 Queen's Gate
London SW7 2AZ

https://jopasser.at

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

_______________________________________________
OpenMOLE-users mailing list
[email protected]
http://fedex.iscpif.fr/mailman/listinfo/openmole-users

Reply via email to