Syncing with a Builder experiment from Coder View

OS Win 10
PsychoPy version 1.84

I read in the forum that we cannot convert code changes back to Builder. But what about updating online? I put my experiment on Pavlovia in Builder, but then I found out I needed to make a few changes in the code. Now those new code changes won’t update on Pavlovia, even when I use the sync button in Coder view. Do I need to upload the entire experiment from scratch to incorporate those changes?

I don’t think you need my experiment or code to answer this question. Thanks.


Yes so the general best practice is:

  1. create exp in builder using builder view
  2. push to pavlovia, if you encounter an error open developer tools to see where in the compiled .js code the error is occuring.
  3. make edits in your builder experiment rather than the code (e.g. from looking at the line in my .js file I see an issue with setting the position of a stimulus, I then go to my builder and change where I set the position)

The idea is that you never directly change any of your code files. (if you make an edit you your .js file, then click sync from your builder, builder will by defualt make a new .js file on the save anyway, so save over your changes. You could change this in your experiment settings in the ‘online’ tab through setting export html to ‘manual’ rather than ‘on sync’). You might sometimes see on the forum people discussing making edits to ‘code’ for online use, this will usually refer to edits in code components where you add snippets of custom code to your builder experiment, rather than the compiled .js script.

Hope this helps,

1 Like

Thanks, Becca. But I’m adapting the onlineIAT that has several components that are set in the code (what information you as individuals to input at the beginning, a fixation cross), so I can’t access those features in Builder. An inserted trial code component will open, but the component I need to open to change the fixation cross in the feedback tab will not open. There does not appear to be a code component inserted to change what information is collected at the beginning of the experiment.

I’ll try your suggestion to change the settings to manual rather than on sync and also what the forum might say about changing code components.

Hi there,

Please can you share the link to the demo you are adapting. If you need to implement a change to the fixation cross, is there a reason you cannot implement those changes in the builder component associated with the fixation point? (I assume it is a text component?). If you want to edit the information gathered in the first gui you can do this by adding fields in experiment settings (cog icon > + icon to add fields).


The way I circumvent this problem was to open my experiment file *.psychopy with an IDE in which I just edited the xml code. It’s a little painful, but much better than to create lots of objects by hand you in fact only wanted to copy with a few adjustments.

BTW: If there’s an easier way to copy objects, please tell me. I tried right-clicking “copy” on the object, but there was no way to paste it (neither with CTRL+V, nor right-click menu, nor Edit/Paste GUI menu).

I copy and paste routines and components all the time in Builder. Are you having an issue within an experiment or from one experiment to another?

No. Within the same experiment. I was referring to, e.g., copying a text element. I can right-click on it, click on /copy/, but I cannot paste it. Neither with CTRL+V, nor right-click, nor anything. How do you do it?

I right-click / copy the component
then Experiment - Paste Component (which I see has a keyboard shortcut of Ctrl-Alt-V)

WOW. I’d never… I’d never have expected stuff that clearly belongs to the “Edit” category to end up under the “Experiment” tab. Thank you! (Especially for the mention of hotkeys.) That xml stuff was annoying (but good to know anyway).