Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

html: AudioNode.connect does not honor the optional-ness of the 3rd argument (input) #6728

Closed
kevmoo opened this issue Nov 14, 2012 · 16 comments
Assignees
Labels
web-libraries Issues impacting dart:html, etc., libraries
Milestone

Comments

@kevmoo
Copy link
Member

kevmoo commented Nov 14, 2012

AudioNode advertises the connect method as:

void connect(destination, int output, [int input])

When the input value is omitted, though, one gets a null ref exception.

r14873

work around: provide 0 for input

@madsager
Copy link
Contributor

Added Area-HTML, Triaged labels.

@efortuna
Copy link
Contributor

efortuna commented Dec 6, 2012

Set owner to @efortuna.
Added this to the M3 milestone.

@efortuna
Copy link
Contributor

This is looking like a dartium-html problem. It works just fine when compiled to JS.

@kevmoo
Copy link
Member Author

kevmoo commented Dec 19, 2012

Not surprised since JS doesn't mind missing params...

@efortuna
Copy link
Contributor

update: We've isolated the problem, but we're still in discussions for that the best solution is (it's part of a broader problem). In the meantime, provide 0 as you mentioned.

Expect this to come in early M4.


Removed this from the M3 milestone.
Added this to the M4 milestone.

@gramster
Copy link

gramster commented Mar 7, 2013

Just to add to this - only the first argument should actually be non-optional. According to W3C:

interface AudioNode {

    void connect(AudioNode destination, optional unsigned long output = 0, optional unsigned long input = 0);
    void connect(AudioParam destination, optional unsigned long output = 0);
    ...
}

From what I have seen of JS web audio code, it is common to only supply the first argument, so we are violating the principle of least surprise here.

@efortuna
Copy link
Contributor

Graham, actually that part of the interface is AsDesigned. See the explanation here: https://code.google.com/p/dart/issues/detail?id=2023

HOWEVER, I do agree that it is very strange. I've been in discussions with the other html lib folk and I think we'll be making a change on this, but it's going to be pretty big in scope and affects a number of other issues in the library (that's what the holdup is on resolving this bug).

@efortuna
Copy link
Contributor

Marked this as being blocked by #9156.

@blois
Copy link
Contributor

blois commented Apr 3, 2013

Removed this from the M4 milestone.
Added this to the M5 milestone.

@kevmoo
Copy link
Member Author

kevmoo commented Apr 17, 2013

Is it possible to remove the optional-ness of the input arg?

Or at least a doc comment if this isn't going to get fixed. :-/

@sethladd
Copy link
Contributor

@efortuna
Copy link
Contributor

efortuna commented Jun 4, 2013

Issue #11070 has been merged into this issue.

@efortuna
Copy link
Contributor

Added Started label.

@blois
Copy link
Contributor

blois commented Jun 18, 2013

Removed this from the M5 milestone.
Added this to the M6 milestone.

@efortuna
Copy link
Contributor

efortuna commented Jul 3, 2013

At long last, fixed as of r24709!


Added Fixed label.

@kevmoo
Copy link
Member Author

kevmoo commented Jul 11, 2013

Verified on 0.6.3.3_r24898

@kevmoo kevmoo added Type-Defect web-libraries Issues impacting dart:html, etc., libraries labels Jul 11, 2013
@kevmoo kevmoo added this to the M6 milestone Jul 11, 2013
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
web-libraries Issues impacting dart:html, etc., libraries
Projects
None yet
Development

No branches or pull requests

6 participants