QutEcoacoustics / baw-client

The AngularJS client for the bioacoustic workbench
Other
7 stars 1 forks source link

Listen page doesnt play 96khz files #327

Closed peichins closed 6 years ago

peichins commented 6 years ago

96khz recordings do not load on the listen page. Not sure if the problem is with baw-client or baw server. Some examples: https://www.ecosounds.org/listen/461001 https://www.ecosounds.org/listen/523273

Quick inspection of the media.json seems ok:

{"meta":{"status":200,"message":"OK"},"data":{"recording":{"id":523273,"uuid":"ee4fb868-067f-4761-bfc0-8860e73e56ab","recorded_date":"2018-01-31T04:30:43.000+10:00","duration_seconds":9643.627,"sample_rate_hertz":96000,"channel_count":1,"media_type":"audio/wav"},"common_parameters":{"start_offset":0.0,"end_offset":30.0,"audio_event_id":null,"channel":0,"sample_rate":96000},"available":{"audio":{"webm":{"media_type":"audio/webm","extension":"webm","url":"/audio_recordings/523273/media.webm?end_offset=30\u0026start_offset=0"},"ogg":{"media_type":"audio/ogg","extension":"ogg","url":"/audio_recordings/523273/media.ogg?end_offset=30\u0026start_offset=0"},"flac":{"media_type":"audio/x-flac","extension":"flac","url":"/audio_recordings/523273/media.flac?end_offset=30\u0026start_offset=0"},"wav":{"media_type":"audio/wav","extension":"wav","url":"/audio_recordings/523273/media.wav?end_offset=30\u0026start_offset=0"}},"image":{"png":{"window_size":512,"window_function":"Hamming","colour":"g","ppms":0.1875,"media_type":"image/png","extension":"png","url":"/audio_recordings/523273/media.png?end_offset=30\u0026start_offset=0"}},"text":{"json":{"media_type":"application/json","extension":"json","url":"/audio_recordings/523273/media.json?end_offset=30\u0026start_offset=0"}}}}}

The following error occurs on the listen page on these files (this is most likely a downstream symptom of the actual bug):

baw-client-1.5.1.js:15 TypeError: Cannot read property 'url' of undefined
    at Media cache ahead.request (baw-client-1.5.1.js:67)
    at Array.i (baw-client-1.5.1.js:67)
    at Array.map (<anonymous>)
    at j (baw-client-1.5.1.js:67)
    at baw-client-1.5.1.js:67
    at Object.d [as forEach] (baw-client-1.5.1.js:13)
    at baw-client-1.5.1.js:67
    at q (baw-client-1.5.1.js:16)
    at l (baw-client-1.5.1.js:67)
    at m (baw-client-1.5.1.js:67)
baw-client-1.5.1.js:15 Broken interceptor detected: Config object not supplied in rejection:
 https://github.com/chieffancypants/angular-loading-bar/pull/50
baw-client-1.5.1.js:62 
baw-client-1.5.1.js:62 retrieval of media json failed
Bookmark saving error Arguments [TypeError: Cannot read property 'url' of undefined
    at Media cache ahead.request (https://www.eco…, callee: (...), Symbol(Symbol.iterator): ƒ]
peichins commented 6 years ago

Preparing to harvest some 96khz to staging, under "phil's test project": https://staging.ecosounds.org/projects/1011/sites/1262