Return-Path: X-Original-To: apmail-incubator-callback-dev-archive@minotaur.apache.org Delivered-To: apmail-incubator-callback-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 19C7DD1AA for ; Wed, 5 Sep 2012 04:21:20 +0000 (UTC) Received: (qmail 15606 invoked by uid 500); 5 Sep 2012 04:21:19 -0000 Delivered-To: apmail-incubator-callback-dev-archive@incubator.apache.org Received: (qmail 15190 invoked by uid 500); 5 Sep 2012 04:21:11 -0000 Mailing-List: contact callback-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: callback-dev@incubator.apache.org Delivered-To: mailing list callback-dev@incubator.apache.org Received: (qmail 15147 invoked by uid 99); 5 Sep 2012 04:21:10 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Sep 2012 04:21:10 +0000 X-ASF-Spam-Status: No, hits=2.5 required=5.0 tests=FRT_ADOBE2,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of agrieve@google.com designates 209.85.210.175 as permitted sender) Received: from [209.85.210.175] (HELO mail-iy0-f175.google.com) (209.85.210.175) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Sep 2012 04:21:05 +0000 Received: by iaky10 with SMTP id y10so153516iak.6 for ; Tue, 04 Sep 2012 21:20:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:content-type :x-system-of-record; bh=eNWFlFbkQJ6JZXXS6Fn+OcVtFQFk4ywKiqC4BuZT3xc=; b=E3UeROuDTg3XEqfoiZ5hnGhc1MtEA2wbp2wxaZT6wlMZ9f8nfiOFHrQ/dc4yudjU+8 uyuH9a0XZzrF6Z1q88368++Kba8lm0SJCNROSP/o0BitXtPXcjWwoSwJMDftjSS1wAfU wnTrG85fA4EbvS1cJ1LrI59gb3ftHM3Dio05XPDbdage93gUQ8j+M1cWOLwfNNv9mX3x ErOvjDVcz7j8AQoVeqC2JUMNpuaBc7flbCgfdEIRH+sHyxTEjyxMdKvWuK+fZIjPD0Wz YOVeN+/tLYTxQiJNXG9ttv3fLCVF1O3Ts26+CBv2y8OhR6c3q9cE+jUQqGB0DbwN68rP 2MBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:content-type :x-system-of-record:x-gm-message-state; bh=eNWFlFbkQJ6JZXXS6Fn+OcVtFQFk4ywKiqC4BuZT3xc=; b=Ws+LisMYg0ZAKDba3eLrgB107r+KkGMoZA1vtmHGYA2/xsCZyDYMosIkGi/TPXkNgu te1xBkbap6c1ey7QGrbX6GvlmOocgT5/PZFlR9qWVrLGgtRL+NsCQWydz4x3KJGlAQzh 9m7t+GkJIqci/HZOsAOM5JvIii+x46zlLCsFkDPlQurSsrpfdfItXdJ72K6tWRB5BIFL m3Sn15u/ppzMplHfeKFuFhKmqVZpc+giN0ZfcwiDsO4IAPZXO6kuY5CgERnb9yHDLKiD LJ957XfOMFp/Sso7Z+uCqttFMf3QALRZTxHKXQPMd30pgnrqgx9m0up+VegIkVYTT+V+ 3vvw== Received: by 10.60.169.75 with SMTP id ac11mr16677116oec.12.1346818844611; Tue, 04 Sep 2012 21:20:44 -0700 (PDT) Received: by 10.60.169.75 with SMTP id ac11mr16677114oec.12.1346818844338; Tue, 04 Sep 2012 21:20:44 -0700 (PDT) MIME-Version: 1.0 Sender: agrieve@google.com Received: by 10.182.125.71 with HTTP; Tue, 4 Sep 2012 21:20:24 -0700 (PDT) In-Reply-To: References: From: Andrew Grieve Date: Wed, 5 Sep 2012 00:20:24 -0400 X-Google-Sender-Auth: A7wmY-fLDbvzWn70mue0zUvRkxA Message-ID: Subject: Re: The spec defines the docs which defines the tests which defines the implementation, and other dependency issues To: callback-dev@incubator.apache.org Content-Type: multipart/alternative; boundary=bcaec54d47a4cb28d604c8ecb24e X-System-Of-Record: true X-Gm-Message-State: ALoCoQm0lYX0F5d7cNumhtx76ddIVhQ1Xk1mQ0BiVuEn1brcv/Soriap0Kjrba227XnyDdP6Rjt6FADS76qZ1jxtFqE/w487YrzX2bfO7/btt0uO8cZWeTpwYGkpZ4n10N6gtjDRO1jXS3nIKdzc4wnCAE5HH/cbfhkJD3pFF1C7WWoZ/y92htBY8L+OyNLH3A5N6R/Q8ig2AKDMmztuQFyon86Oi2GYfQ== X-Virus-Checked: Checked by ClamAV on apache.org --bcaec54d47a4cb28d604c8ecb24e Content-Type: text/plain; charset=ISO-8859-1 Maybe just add MEDIA_ERR_SRC_NOT_SUPPORTED alongside MEDIA_ERR_NONE_ SUPPORTED? On Tue, Sep 4, 2012 at 5:01 PM, Filip Maj wrote: > This API was written against an earlier revision of this spec so the > codes/labels have likely changed. > > Changing stuff requires changes to reflect across all platforms. That's my > only concern at this point. > > I would shy away from changing anything. It's make-work until we review > the API(s) in the coming months anyways. > > As for this specific scenario.. Fuck. I dunno. I would update the docs to > reflect the JS + tests? > > On 9/4/12 1:08 PM, "Jesse" wrote: > > >I am trying to chase down a few failing tests, here is one of the > >simpler cases I am having to deal with. > >I need to know which of the following is correct. > >( note that there are numerous other similar cases like this > >throughout our code base ) > > > >The W3 Spec for MediaError is [1] : > > > >interface MediaError { > > const unsigned short MEDIA_ERR_ABORTED = 1; > > const unsigned short MEDIA_ERR_NETWORK = 2; > > const unsigned short MEDIA_ERR_DECODE = 3; > > const unsigned short MEDIA_ERR_SRC_NOT_SUPPORTED = 4; > > readonly attribute unsigned short code; > >}; > > > >The phonegap edge docs state [2]: > > > >MediaError.MEDIA_ERR_ABORTED > >MediaError.MEDIA_ERR_NETWORK > >MediaError.MEDIA_ERR_DECODE > >MediaError.MEDIA_ERR_NONE_SUPPORTED > > > >The tests are testing for [3] : > > > >expect(MediaError.MEDIA_ERR_NONE_ACTIVE).toBe(0); > >expect(MediaError.MEDIA_ERR_ABORTED).toBe(1); > >expect(MediaError.MEDIA_ERR_NETWORK).toBe(2); > >expect(MediaError.MEDIA_ERR_DECODE).toBe(3); > >expect(MediaError.MEDIA_ERR_NONE_SUPPORTED).toBe(4); > > > >The cordova js repo defines this [4] : > > > >MediaError.MEDIA_ERR_NONE_ACTIVE = 0; > >MediaError.MEDIA_ERR_ABORTED = 1; > >MediaError.MEDIA_ERR_NETWORK = 2; > >MediaError.MEDIA_ERR_DECODE = 3; > >MediaError.MEDIA_ERR_NONE_SUPPORTED = 4; > > > >How should I resolve this? > >Can we remove MEDIA_ERR_NONE_ACTIVE ? > >Can we re-define 4 as MEDIA_ERR_SRC_NOT_SUPPORTED instead of > >MEDIA_ERR_NONE_SUPPORTED ? > >Can we change our js code to only write the MediaError interface if it > >does not exist? > > > >[1] http://dev.w3.org/html5/spec-author-view/video.html#error-codes > >[2] > >http://docs.phonegap.com/en/edge/cordova_media_media.md.html#mediaError > >[3] > > > https://github.com/apache/incubator-cordova-mobile-spec/blob/master/autote > >st/tests/media.tests.js > >[4] > > > https://github.com/apache/incubator-cordova-js/blob/master/lib/common/plug > >in/MediaError.js > >-- > >@purplecabbage > >risingj.com > > --bcaec54d47a4cb28d604c8ecb24e--