Drag and drop online experiment crashes when using ipad

I’m not sure if this is your issue, but your code is moving items on every frame when the mouse button is clicked, which can cause a memory overload. I would check that the coordinates are different before updating the position (equating x and y separately).

Thanks Sotiri. It does seem to run but there is no sound. Also it takes a while before it allows me to move a object.
Your comment about using mp3 files. I thought you couldn’t use them in psychopy because of licensing issues.

I have 4 experiments which all exhibit the same problem how do I apply your fix to each of them. Also if I make changes in psychopy offline and then re-upload it will it still work.

Thanks Phil

Thanks Wakefield for you reply. I got a response from Sotiri in which he got it to work but you suggestion is a good idea and I will look into implementing it.

Phil

.mp3 files can’t be used offline but are the best format online.

My experiment developed offline on psychopy references sound .wav files. How do I make the online version use .mp3 files easily?

.wav files can work online as well. It’s .ogg files that don’t.

However, what I do is have the filename minus the extension in the Excel file (or whatever) and then use a both component to add the appropriate extension.

Alternatively, if you set a flag early in the experiment (in a Both component, such as useOnline=0 in Python and useOnline=1; in Javascript) then you could add an if statement to either search and replace .wav with .mp3 or add the appropriate extension in an auto code component later.

You’ll need to add the .mp3 files in the resources section of the online tab of experiment settings.

Hi @philBartlett, OK the fix I gave you is available with the latest version of PsychoPy, which was just announced today, have you a reason to not upgrade? x

Personally I’d hold out for 2021.1.1 to catch the first round of bug fixes.

OK in case upgrading is not an option, one would need to edit the default index.html each time ‘Export HTML’ is called to link to the latest version of howler.js, which does support .wav playback

1 Like

Hi Sotiri,

I don’t know any reason why I wouldn’t update to the latest. I will give it a try tomorrow.

Thanks Phil

Sotiri,

I updated to the latest version of psychopy and when I tried to sync with Pavlovia I got an error. The tracback file is enclosed.
Do I need to create new experiments on Pavlovia?

Phil

(Attachment psychopy_traceback.txt is missing)

It didn’t like the attachment so I have pasted it below.

Traceback (most recent call last):
File “C:\Program Files\PsychoPy3\lib\site-packages\psychopy\app\builder\builder.py”, line 1325, in onPavloviaSync
retVal = pavlovia_ui.syncProject(parent=self, project=self.project)
File “C:\Program Files\PsychoPy3\lib\site-packages\psychopy\app\builder\builder.py”, line 1416, in project
elif self.filename and pavlovia.getProject(self.filename):
File “C:\Program Files\PsychoPy3\lib\site-packages\psychopy\projects\pavlovia.py”, line 1068, in getProject
gitRoot = getGitRoot(filename)
File “C:\Program Files\PsychoPy3\lib\site-packages\psychopy\projects\pavlovia.py”, line 1049, in getGitRoot
cwd=str§).decode(‘utf-8’):
File “C:\Program Files\PsychoPy3\lib\subprocess.py”, line 336, in check_output
**kwargs).stdout
File “C:\Program Files\PsychoPy3\lib\subprocess.py”, line 418, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command ‘[‘git’, ‘branch’, ‘–show-current’]’ returned non-zero exit status 129.

Hi @philBartlett, thanks for the traceback, is the project still on git? @TParsons any ideas?

This is a bug unfortunately, and quite an urgent one; Jon has a fix for it already so you can expect the .1 release to be out either today or tomorrow at the latest. Update to that when it’s out and it should be fixed :slight_smile:

1 Like

Ah cool, thanks @TParsons :blush:

Thanks for the update