trouble using the inline script logger
Hi all,
I tried using the logger in an inline script as I need to log variables in an inline loop.
I wrote: " log.write_vars()"
And I get the error message:
Error while executing inline script
item-stack: experiment[run].Ego_depletion_task[run].new_inline_script[run]
exception type: ValueError
exception message: I/O operation on closed file.
item: new_inline_script
time: Sun Oct 15 18:13:21 2017
phase: run
What am I missing here?
Thanks!

Comments
Hi Amir,
I suspect that you've inadvertently closed the logfile, and then try to write to it. For example, the following script will result in the error that you're seeing, and something similar is probably going on in your experiment.
Could that be it?
Cheers,
Sebastiaan
Check out SigmundAI.eu for our OpenSesame AI assistant!
Hi Sebastiaan,
Yes, now that you bring it up, there is something in the setup of the experiment, that I put in to create unique logfiles. I looks like the log file is reopened though, but I gues it was only initialised.
I added this line and now it works, thanks!
Good!
Check out SigmundAI.eu for our OpenSesame AI assistant!