Add bindings for inline audio playback in the search page

Bug #1541911 reported by ric silva
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
unity-js-scopes
Fix Committed
Undecided
Alexandre Abreu

Bug Description

According to the ubuntu-on-air session on javascript scopes, the javascript bindings don't have support for the new audio cards that allow previewing audio directly on the search page (as is the case on the My Music scope).

Can this be added? Please :)

Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

Hmmm, it seems that this is actually supported, although documentation on how to use it is missing from our base API (Bug #1542216)

Once the docs have been updated I'll report back on what it should look like in JS.

Changed in unity-js-scopes:
assignee: nobody → Marcus Tomlinson (marcustomlinson)
status: New → In Progress
Changed in unity-js-scopes:
assignee: Marcus Tomlinson (marcustomlinson) → Alexandre Abreu (abreu-alexandre)
Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

Alex, didn't you add inline playback to our soundcloud example scope?

Could you please give a quick explanation as to how inline playback can be added to a JavaScript scope here?

Then I think we can close this bug.

Revision history for this message
Alexandre Abreu (abreu-alexandre) wrote :

@Marcus: yes I did but the work is not complete and atm not working properly in soundcloud, there is a larger issue w/ sharing plain URIs w/ foreign entities without additional context (in this case w/o credentials),

In this case, the URI resource when being accessed by the MH triggers a :

** Media playback error: 4

which is an access denied,

most likely because there needs to be some user credentials (account) associated w/ the request which is not possible with the current scope URI sharing API.

Revision history for this message
ric silva (ricardo-garcia-silva) wrote :

Hi alex, marcus

That is weird. I actually took inspiration from the soundcloud sample in order to implement inline audio playback in my freesound scope, which was done using the javascript bindings. This is working OK in the phone using the stable channel.

I could not get it working on the desktop, but it works just fine on the phone.

Best regards

Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

Glad to hear you managed to figure it out Ricardo! Let's consider the bug resolved.

For anyone stumbling across this bug and would like to know how inline playback is used, please check out the documentation updates associated with Bug #1542216. You can also check out the soundcloud example scope in unity-js-scopes for an example of how it is utilised in JS.

Changed in unity-js-scopes:
status: In Progress → Fix Committed
Revision history for this message
Alexandre Abreu (abreu-alexandre) wrote :

@ric: it depends on how the website deals with the incoming URL requests (here from the media hub), they might not require extra context at all,

So here the mechanic works overall (from the POV of the scopes & unity dash) but the website refuses to hand off the stream to us,

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.