Re: [Json] Using a non-whitespace separator (Re: Working Group Last Call on draft-ietf-json-text-sequence)

Nico Williams <nico@cryptonector.com> Sun, 01 June 2014 23:16 UTC

Return-Path: <nico@cryptonector.com>
X-Original-To: json@ietfa.amsl.com
Delivered-To: json@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 5F4581A00D7 for <json@ietfa.amsl.com>; Sun, 1 Jun 2014 16:16:46 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.044
X-Spam-Level:
X-Spam-Status: No, score=-1.044 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FM_FORGED_GMAIL=0.622, IP_NOT_FRIENDLY=0.334, RCVD_IN_DNSWL_NONE=-0.0001] autolearn=no
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id c3CbdocnXkQs for <json@ietfa.amsl.com>; Sun, 1 Jun 2014 16:16:45 -0700 (PDT)
Received: from homiemail-a29.g.dreamhost.com (sub4.mail.dreamhost.com [69.163.253.135]) by ietfa.amsl.com (Postfix) with ESMTP id A37361A00CF for <json@ietf.org>; Sun, 1 Jun 2014 16:16:45 -0700 (PDT)
Received: from homiemail-a29.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a29.g.dreamhost.com (Postfix) with ESMTP id C832E674059 for <json@ietf.org>; Sun, 1 Jun 2014 16:16:40 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=cryptonector.com; h= mime-version:in-reply-to:references:date:message-id:subject:from :to:cc:content-type; s=cryptonector.com; bh=2OcPUquzJF65nCfTFVRM Cz+ZYsw=; b=V2NvPeHjd+fb1nV+ZFvzr2YSoSbb7MYpuyrq8vlGh/UvZ08ZDtbz 5M6CMn7d5TFMxV0CKhPLsXaw9Kcspf7NZ5N9EzmeVuBUwiyTt2aa+dEmL2IQV+21 B2AMcOnTpx0OgRY6D2yHiIAx5flIWWKG9jICKI0VqnEBXqAD0/Jnx7Q=
Received: from mail-wg0-f42.google.com (mail-wg0-f42.google.com [74.125.82.42]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: nico@cryptonector.com) by homiemail-a29.g.dreamhost.com (Postfix) with ESMTPSA id 7B318674058 for <json@ietf.org>; Sun, 1 Jun 2014 16:16:40 -0700 (PDT)
Received: by mail-wg0-f42.google.com with SMTP id y10so4246545wgg.13 for <json@ietf.org>; Sun, 01 Jun 2014 16:16:39 -0700 (PDT)
MIME-Version: 1.0
X-Received: by 10.194.8.6 with SMTP id n6mr27600093wja.31.1401664599486; Sun, 01 Jun 2014 16:16:39 -0700 (PDT)
Received: by 10.216.29.200 with HTTP; Sun, 1 Jun 2014 16:16:39 -0700 (PDT)
In-Reply-To: <15F00865-592D-41B2-8E23-6C794C4B77EF@vpnc.org>
References: <CAK3OfOidgk13ShPzpF-cxBHeg34s99CHs=bpY1rW-yBwnpPC-g@mail.gmail.com> <CAHBU6itr=ogxP4uoj57goEUSOCpsRx1AXVnW1NQwSTPxbbttkw@mail.gmail.com> <CAK3OfOhft+XJeMrg5rdY9E6fxAkJ2qsT3UHwu7zt=NEz2Q3XOQ@mail.gmail.com> <15F00865-592D-41B2-8E23-6C794C4B77EF@vpnc.org>
Date: Sun, 01 Jun 2014 18:16:39 -0500
Message-ID: <CAK3OfOgWtJQtXGQR3GqRpFJBzAPpy0NvTeDeTSYhqa7-FDhqbw@mail.gmail.com>
From: Nico Williams <nico@cryptonector.com>
To: Paul Hoffman <paul.hoffman@vpnc.org>
Content-Type: text/plain; charset="UTF-8"
Archived-At: http://mailarchive.ietf.org/arch/msg/json/6_tOpeCxq2pWEqaDe8XvXmGaPtk
Cc: IETF JSON WG <json@ietf.org>
Subject: Re: [Json] Using a non-whitespace separator (Re: Working Group Last Call on draft-ietf-json-text-sequence)
X-BeenThere: json@ietf.org
X-Mailman-Version: 2.1.15
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: Sun, 01 Jun 2014 23:16:46 -0000

On Sun, Jun 1, 2014 at 6:10 PM, Paul Hoffman <paul.hoffman@vpnc.org> wrote:
> On Jun 1, 2014, at 3:35 PM, Nico Williams <nico@cryptonector.com> wrote:
>> On Sun, Jun 1, 2014 at 12:08 AM, Tim Bray <tbray@textuality.com> wrote:
>>> No. There should be only one way to do things.
>>
>> I'm not terribly fond of this.
>>
>> It'd be easier if we picked a Unicode whitespace character that's not
>> used in the JSON whitespace rule and must be escaped in strings,
>> preferably one that terminals and such generally handle as a
>> whitespace.
>
> What would a whitespace character be "easier" than a character not allowed in Unicode? It seems to me that a character that could not exist in a string and therefore never needs to be escaped is "easier".

Because I want text-based tools to be able to at least display (and
grep, and...) JSON text sequence contents much as they can JSON text
contents.

>> Failing that a character that terminals will ignore.
>
> I suspect most terminals would ignore FEFF. But I don't think that's actually as important as the fact that it doesn't require escaping.

Right, it has to be a character that must be escaped, and its encoding
must require a single byte, otherwise we can't recover simply from
incomplete appends.

>> But since the problem we're talking about is only relevant to log-like
>> writing patterns, I'd prefer to make this optional for writers,
>> mandatory for readers.
>
> Make what optional for writers and mandatory for readers?

I'd like what jq does now to continue to be valid.  I'd like to add an
alternate separator for the log-file case.

Nico
--