Re: [Json] JSON and int64s - any change in current best practice since I-JSON

Pete Cordell <petejson@codalogic.com> Wed, 17 January 2024 09:10 UTC

Return-Path: <petejson@codalogic.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 90005C14F70F for <json@ietfa.amsl.com>; Wed, 17 Jan 2024 01:10:20 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.104
X-Spam-Level:
X-Spam-Status: No, score=-2.104 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01, URIBL_BLOCKED=0.001, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=codalogic.com
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id t_ucaMZG03Y1 for <json@ietfa.amsl.com>; Wed, 17 Jan 2024 01:10:16 -0800 (PST)
Received: from sxb1nlsmtp02.prod.sxb1.secureserver.net (sxb1nlsmtp02.prod.sxb1.secureserver.net [92.204.71.169]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id E3D0AC1519A2 for <json@ietf.org>; Wed, 17 Jan 2024 01:09:56 -0800 (PST)
Received: from codalogic.com ([92.205.28.31]) by : HOSTING RELAY : with ESMTP id Q1unr60eceDH9Q1unr9YVw; Wed, 17 Jan 2024 02:08:54 -0700
X-SECURESERVER-ACCT: 92.205.28.31
x-originating-ip: 92.205.28.31
X-CMAE-Analysis: v=2.4 cv=e6ulSrp/ c=1 sm=1 tr=0 ts=65a79926 a=JLy5cBbKnJYyhq39FObxXg==:117 a=JLy5cBbKnJYyhq39FObxXg==:17 a=IkcTkHD0fZMA:10 a=dEuoMetlWLkA:10 a=cW0VwewdAAAA:8 a=eYs_uXBrtQlrAcVEe8QA:9 a=QEXdDO2ut3YA:10 a=iS4WXqH-_IHI08BRIDHb:22
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=codalogic.com; s=default; t=1705482533; bh=tILBIMw+H5xUZqSqDQF3cpA3a4E692TqXItlx2QgJbk=; h=Received:Received:Subject:To:From; b=PSlgknByDgoseY/C5xrfYY51P9VJ8CVFOQ0OGjgc0o/ybXf4DCbAEDOZVnyfDaByp uZIUqnxZWuUxCKpPItEnzDMPEyTDDyfuLeyQQ8Ncp2s6X6AIcOVqZscS6sIo4x+Wtp ZF+vJttN5ELNoA4//8wmnKp7GUJ0q+/KzvF88f3Q=
Received: (qmail 24773 invoked from network); 17 Jan 2024 09:08:53 +0000
Authentication-Results: 31.28.205.92.host.secureserver.net; spf=pass (sender IP is 86.181.217.85) smtp.mailfrom=petejson@codalogic.com smtp.helo=[192.168.1.72]
Received-SPF: pass (31.28.205.92.host.secureserver.net: connection is authenticated)
Received: from host86-181-217-85.range86-181.btcentralplus.com (HELO ?192.168.1.72?) (86.181.217.85) by 31.28.205.92.host.secureserver.net with ESMTPSA (AES128-GCM-SHA256 encrypted, authenticated); 17 Jan 2024 09:08:53 +0000
Message-ID: <33849a11-0fb6-4495-9e66-fa000d5ea825@codalogic.com>
Date: Wed, 17 Jan 2024 09:08:52 +0000
MIME-Version: 1.0
User-Agent: Mozilla Thunderbird
To: Tim Bray <tbray@textuality.com>, Joe Hildebrand <hildjj@cursive.net>
Cc: "json@ietf.org" <json@ietf.org>
References: <87527a42-aaac-4f39-b320-05f18a2808c1@codalogic.com> <C31BF4C8-9E6C-48F8-BF7B-D2C379273B3F@tzi.org> <CAHBU6it4SaLawSiBgK9ySkbxjtHE6CX-P3r=hzcVy4ksoQo-Cg@mail.gmail.com> <CAChr6SxHfLW-A1asAndKJz-AiyJv5QP18bi=_bNdKXw7zYHThw@mail.gmail.com> <CAChr6SweYdCWxSABZ7g20Zd-xBFzcK0Ritq53S7WtjSwc-vLmw@mail.gmail.com> <E5A68370-CC2F-4618-AB39-39A382656616@cursive.net> <CAHBU6itRMhFk-38LPnB=c4vjZuDEp+UVXiQPzKrCwVmugUizag@mail.gmail.com>
Content-Language: en-GB
From: Pete Cordell <petejson@codalogic.com>
In-Reply-To: <CAHBU6itRMhFk-38LPnB=c4vjZuDEp+UVXiQPzKrCwVmugUizag@mail.gmail.com>
Content-Type: text/plain; charset="UTF-8"; format="flowed"
Content-Transfer-Encoding: 7bit
X-CMAE-Envelope: MS4xfNdGTF2Z5oHNEHBNIet0cXwvlPPtxZ+Uw/47fhHYkPrfyueFkRGzGLpveetjVRVm5m2g7ePtJqVepK2F0L2AtQa4fiWFqloSkBgZ8dJRGgGNWF+64IiI 4+mjJyH4eaSZ2WCPNfuVR4bXyg4ljqNe2fZ2c+OH8Ka1RwqdU03hikHKhedd+gPzTGWfFDMGwrWXMg==
Archived-At: <https://mailarchive.ietf.org/arch/msg/json/3q_7zsKVyAe5Cc0_fcLz7ro5mjQ>
Subject: Re: [Json] JSON and int64s - any change in current best practice since I-JSON
X-BeenThere: json@ietf.org
X-Mailman-Version: 2.1.39
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: <https://mailarchive.ietf.org/arch/browse/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, 17 Jan 2024 09:10:20 -0000

On 17/01/2024 05:01, Tim Bray wrote:
> I would so so love to fix up JSON just a little bit. Lose the 
> (syntactically superfluous) commas, RFC3733 date literals, add a couple 
> of numeric types. I can dream the impossible dream.

At the risk of veering off course, I also find JSON harder to edit than 
I feel it ought to be.

I ended up defining a JSON like syntax that is stripped down but also 
allows comments and multi-line text.  I called it Line Oriented Object 
Notation (LOON) and it's a dream to use compared to manually editing JSON.

In a nutshell, for JSON like:

{
     "name" : "Pete",
     "userid" : 12,
     "privileges" : [
         {
             "directory" : "/home/pete",
             "permissions" : "rwxd"
         },
         {
             "directory" : "/bin",
             "permissions" : "rx"
         }
     ]
}

you have LOON like:

# Pete's user profile
name : Pete
userid: 12
privileges [
     {
         directory: /home/pete
         permissions: rwxd
     }
     {
         directory: /bin
         permissions: rx
     }
]

One day I hope to recast the JSON RFC to describe LOON and present it. 
Until then, there's a blog post that says a little more for those that 
might be interested:

    https://codalogic.com/blog/2023/02/30/Line-Oriented-Object_notation

Pete.
-- 
---------------------------------------------------------------------
Pete Cordell
Codalogic Ltd
---------------------------------------------------------------------