Audio verse selection restarts chapter

I just updated a Scriptoria app to add opus (.webm) audio files. (I created those .webm files directly from the .FCBH .mp3 files, but they seem to be almost the same as the -opus16 files that get downloaded from FCBH.) Everything seems to be working well, with one exception: The audio always starts from the beginning of the chapter. If I tap on a verse number to select a verse and press play audio, it unselects the verse and goes back to the beginning of the chapter, playing audio and highlighting there. As audio is being played, I’m used to being able to tap on a verse number, and the audio will jump to that verse number. If I do that in this app, it will jump back to the beginning of the chapter.

I know that this is not a problem with the -opus16 format. I have another app which uses .webm files I created in the same way, and it works as expected. The main differences I can think of are:

  • the app that works has the audio files embedded in the app, and the one that doesn’t downloads them from FCBH (or pulls them from a folder on the device)
  • the app that doesn’t work was an older project that was downloaded from Scriptoria

Any thoughts as to what could be wrong? This app isn’t publishable as is…

This problem is reported with sample projects in the GitHub issues: https://github.com/sillsdev/app-builders/issues/1258.

The resolution to this problem isn’t described in that GitHub post… We did manage to get around this problem, but I couldn’t find details on the solution that we used anywhere.

But I seemed to recall that it had to do with something weird about the .webm files being used. To make sure that the .webm file is right in every way, from within SAB, use the convert audio file tool, even if you are converting it to the identical format. E.g. I told it to convert to webm, 16kbps (which is what the original audio files were), then I put the created files back into the original folder, rebuilt the app, and the audio playback problem of always restarting the chapter seems to be fixed.