Re: [Json] The names within an object SHOULD be unique.

Vinny A <jsontest@yahoo.com> Wed, 05 June 2013 22:47 UTC

Return-Path: <jsontest@yahoo.com>
X-Original-To: json@ietfa.amsl.com
Delivered-To: json@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id E69CB21F9648 for <json@ietfa.amsl.com>; Wed, 5 Jun 2013 15:47:15 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: 1.257
X-Spam-Level: *
X-Spam-Status: No, score=1.257 tagged_above=-999 required=5 tests=[BAYES_20=-0.74, HTML_MESSAGE=0.001, J_CHICKENPOX_35=0.6, MIME_QP_LONG_LINE=1.396]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aiMtr1oIjKMn for <json@ietfa.amsl.com>; Wed, 5 Jun 2013 15:47:10 -0700 (PDT)
Received: from nm29-vm1.bullet.mail.bf1.yahoo.com (nm29-vm1.bullet.mail.bf1.yahoo.com [98.139.213.144]) by ietfa.amsl.com (Postfix) with ESMTP id C2F9E21F9622 for <json@ietf.org>; Wed, 5 Jun 2013 15:47:09 -0700 (PDT)
Received: from [98.139.215.142] by nm29.bullet.mail.bf1.yahoo.com with NNFMP; 05 Jun 2013 22:46:45 -0000
Received: from [98.139.213.7] by tm13.bullet.mail.bf1.yahoo.com with NNFMP; 05 Jun 2013 22:46:45 -0000
Received: from [127.0.0.1] by smtp107.mail.bf1.yahoo.com with NNFMP; 05 Jun 2013 22:46:45 -0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1370472405; bh=pHJ+54SXV8GVWHkOIc2Mp9n1DPySkdR0lM8EDytv9F8=; h=X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:X-Rocket-Received:References:In-Reply-To:Mime-Version:Content-Type:Received:Message-Id:Content-Transfer-Encoding:Cc:X-Mailer:From:Subject:Content-Length:Date:To; b=zs5Jff8DJfPVWnLZG06ZW2asPsfG8e3E7JZcaHYjvnVX1fTNPbU4LsgDHSJFGxSA07ycRTgKxon2a/JCLqjTWMZ8KXWDPIM3NlIyd+jklhWWbNjwO6PG7stMMKF0opT171w3BgK+9E2nd7YgQ9xNqa15Hrgmtk3HWTx8hSZvB/k=
X-Yahoo-Newman-Id: 196080.81713.bm@smtp107.mail.bf1.yahoo.com
X-Yahoo-Newman-Property: ymail-3
X-YMail-OSG: yQ81ADgVM1mS4Myb4782olmBNtOtQPwm94dBsdgiwN.20K7 merVWK_vZswsF8LZcIl7ZuPVwwOCF1.nYjeuuqDLK2bmBzdeIDNLs6jAH6r2 RIlxFfS0vn4uCCbXloJ_Q7dh1KZkQmftH73xScZ48plVRz76UQz7SEbU95ry 5oI6TLsNsx..Pe6uDARt.nudXphMU7MKfvQ0BMrRx5u9fbzGEZlRwfSL6W8z SxpGOoZV1iMpVVSJFx5.2vSW0aUxsYzNnXoqeUGhqyjiz40bAt_qJs69suMh mrDNvTwsxEVceMK2lh5gYnGfkuL1H6paOSJn7exdXhJ6JFfKqcK.T9zgxMzy P7euoe_P2Ppsg8YfvtpT1_1nub4VTWCU1wKWSg23E6TmUHzq2unXl4_vrlyS nyvRQRtw.USELFQlKapNPWc4DPM4ocMLmb_Wg0Ltiy_zdWVtSS85JcyoYm_7 cLnDiGIChW.jWg26UIcUT7MwgniKlwW2zdRO0KBcY9.Hr0e.oikrzDoSGm0H 8lUdfop.G
X-Yahoo-SMTP: indQcmSswBC8IKsm6t4aCAPskK3T
X-Rocket-Received: from [192.168.0.102] (jsontest@76.29.100.42 with ) by smtp107.mail.bf1.yahoo.com with SMTP; 05 Jun 2013 15:46:44 -0700 PDT
References: <51AF8479.5080002@crockford.com> <51AF9ACF.5020507@cisco.com> <D0A99569-0915-4862-A7AE-9DE51C2E90C0@yahoo.com> <51AFB3F8.8060708@crockford.com> <8F32953C-C788-4DC9-888E-920E2BEB7FDD@yahoo.com>
In-Reply-To: <8F32953C-C788-4DC9-888E-920E2BEB7FDD@yahoo.com>
Mime-Version: 1.0
Content-Type: multipart/alternative; boundary="Apple-Mail-7E7FE867-5679-4F22-8F7A-017C3D12A7F5"
Received: from [76.29.100.42] by web125606.mail.ne1.yahoo.com via HTTP; Wed, 05 Jun 2013 15:45:08 PDT
Message-Id: <831B8E46-F239-4353-8F95-8DF3F9BD2E78@yahoo.com>
Content-Transfer-Encoding: 7bit
X-Mailer: iPod Mail (9B206)
From: Vinny A <jsontest@yahoo.com>
Date: Wed, 05 Jun 2013 17:46:42 -0500
To: Douglas Crockford <douglas@crockford.com>
Cc: Eliot Lear <lear@cisco.com>, "json@ietf.org" <json@ietf.org>
Subject: Re: [Json] The names within an object SHOULD be unique.
X-BeenThere: json@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: "JavaScript Object Notation \(JSON\) WG mailing list" <json.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/json>, <mailto:json-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/json>
List-Post: <mailto:json@ietf.org>
List-Help: <mailto:json-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/json>, <mailto:json-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 05 Jun 2013 22:47:16 -0000

On Jun 5, 2013, at 4:56 PM, Douglas Crockford <douglas@crockford.com> wrote:
> There are people who interpreted the SHOULD as DON'T HAVE TO and intentionally duplicated the keys. My personal feeling is that we should change the SHOULD to MUST and let those applications break. But the consensus of ECMA TC39 is that the SHOULD must stand.

My personal opinion echoes yours. I understand ECMA's consensus though.

On Jun 5, 2013, at 4:56 PM, Douglas Crockford <douglas@crockford.com> wrote:
> So regrettably, that means we should be explicit about what happens when this particular bad practice is practiced.

Do we need to add this to the draft? As in (not proposing this, but as fodder for discussion): "The names within an object SHOULD be unique. If duplicate names are encountered, the last key:value pair MUST be used."

-----------------
Vinny
www.jsontest.com