Re: [Jmap] [JMAP] CalendarEvent/parse proposition for the JMAP Calendar draft

Robert Stepanek <rsto@fastmailteam.com> Wed, 12 April 2023 08:16 UTC

Return-Path: <rsto@fastmailteam.com>
X-Original-To: jmap@ietfa.amsl.com
Delivered-To: jmap@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id BF64FC15C298 for <jmap@ietfa.amsl.com>; Wed, 12 Apr 2023 01:16:50 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.096
X-Spam-Level:
X-Spam-Status: No, score=-2.096 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, HTML_MESSAGE=0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_PASS=-0.001, 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 (2048-bit key) header.d=fastmailteam.com header.b="NdanMJ74"; dkim=pass (2048-bit key) header.d=messagingengine.com header.b="SSUZtHf+"
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 8VVBnioED8ei for <jmap@ietfa.amsl.com>; Wed, 12 Apr 2023 01:16:46 -0700 (PDT)
Received: from wout5-smtp.messagingengine.com (wout5-smtp.messagingengine.com [64.147.123.21]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 49A27C15C29C for <jmap@ietf.org>; Wed, 12 Apr 2023 01:16:46 -0700 (PDT)
Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.west.internal (Postfix) with ESMTP id 7393632007BE for <jmap@ietf.org>; Wed, 12 Apr 2023 04:16:43 -0400 (EDT)
Received: from imap43 ([10.202.2.93]) by compute3.internal (MEProxy); Wed, 12 Apr 2023 04:16:43 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= fastmailteam.com; h=cc:content-type:content-type:date:date:from :from:in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to; s=fm1; t=1681287403; x= 1681373803; bh=Jdvtnvf+O0c6N+0Ysa1Lng5fObGq9n1/ZoHUnSsgepE=; b=N danMJ74txxI576Yyzb3guUgpNG/TRvypGJaAffHYw+P5+SMiF3NdZ9d3h3Ooy+6J LJvniMtA7Uz1LLPQzbEMkDeNCDMaentShnNyHEh6ZdF+UPKZn33K9tYpYfRhOyJS 8rb/VRn2IZj7x8QnlSqpx0SKM1/ckMZs+X7IlAqOfj+yu3rFncpMOU83z6cOrSbz 1set0shFixYYSSXvalA58I62+F2rS4HZfvcvC7gxe1TqV5jBSqgl9lbLcRGsWIW/ +uaKM1eS9EuwqSCrbiZEwJwIWjklIKGzs8JWl6qrZ+KR1rSuRV4Jeev5H/pShcKR 0/L6ctpQl/+n02SDYLcPA==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm3; t=1681287403; x=1681373803; bh=Jdvtnvf+O0c6N +0Ysa1Lng5fObGq9n1/ZoHUnSsgepE=; b=SSUZtHf+Xn+bwFMb+brhWF12n6O9y yC66OKSLHR2OWeiuojtL90yTYr+7pD6C1mmsh94JROdFcFKqEf0OascWteoOOARn fBWu3BaDGcwBSJod5aax4+jWgBDurdSooHeomUMluAsDwejOcppI0TBX/Y8cop2C LkYOKn1xON5Fa4oOqrGWwz8G0r2zTFiBwiLTsZ4QmauxuZvTGtVVE8rXH9XjZUmh JnQ5Pk5KUEoJvN1XAKU7hLwXcjS0lPDNyyb7mOlT7ZnGmdNabdfsvv0S+byyEfiB QbMEF2hsJOX7jmLAw+0/Fkm/ZnauptrDbJNWXMHwDriFNToYWN2ce3u5g==
X-ME-Sender: <xms:6mg2ZMzMm4Q801J6VCd4zOzbcPK0d50m1FO189GpL8-mgvXyCGfIQw> <xme:6mg2ZASXW2z8XiqRDOUESnSHIGMUy7HqH3M6V-g4VMsVJZsZ5aPQNEYRWydpkVv8c ulL2b5IPkOU4g>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrvdekiedgtdduucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefofgggkfgjfhffhffvufgtsegrtd erreerredtnecuhfhrohhmpedftfhosggvrhhtucfuthgvphgrnhgvkhdfuceorhhsthho sehfrghsthhmrghilhhtvggrmhdrtghomheqnecuggftrfgrthhtvghrnhepheeguedvtd ekhfetgfeufefgvdeuteegfeefleehvddugeejjefhteeugfevveeinecuvehluhhsthgv rhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomheprhhsthhosehfrghsthhmrg hilhhtvggrmhdrtghomh
X-ME-Proxy: <xmx:6mg2ZOU8vROXTpjz1X25bDHBkoxA7b-JOiTrnJ2efz4UkmhsMIkdMw> <xmx:6mg2ZKgXSGrCjHHPIdbNHThFRaEaazrQpu5uSAVrMvkRY4MDv5uzMA> <xmx:6mg2ZODGFsF3GMZ2Dn2RbHbEDIi6b8tSPxBlLFGPLcKVURvsEpjRvA> <xmx:62g2ZBOFFLZc7QZ5Z9zqAznjqVBzEf7xAThcIZgj9vEjhYrpkl16Jg>
Feedback-ID: ia5d944da:Fastmail
Received: by mailuser.nyi.internal (Postfix, from userid 501) id BB0D02D40074; Wed, 12 Apr 2023 04:16:42 -0400 (EDT)
X-Mailer: MessagingEngine.com Webmail Interface
User-Agent: Cyrus-JMAP/3.9.0-alpha0-334-g8c072af647-fm-20230330.001-g8c072af6
Mime-Version: 1.0
Message-Id: <15f76e7b-fd5a-4864-a1de-27779e9aed7c@app.fastmail.com>
In-Reply-To: <ab348779-6122-495a-b3c8-66f5ff280b32@app.fastmail.com>
References: <Mime4j.6.e7ae1c1fa90e3ca2.187745bb130@linagora.com> <ab348779-6122-495a-b3c8-66f5ff280b32@app.fastmail.com>
Date: Wed, 12 Apr 2023 10:16:22 +0200
From: Robert Stepanek <rsto@fastmailteam.com>
To: jmap@ietf.org
Content-Type: multipart/alternative; boundary="dcb7a9edf67b4fa59ee2b840335020c5"
Archived-At: <https://mailarchive.ietf.org/arch/msg/jmap/zk3BUZDFbNTWVuk1LJ5fc7hJ0cY>
Subject: Re: [Jmap] [JMAP] CalendarEvent/parse proposition for the JMAP Calendar draft
X-BeenThere: jmap@ietf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: JSON Message Access Protocol <jmap.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/jmap>, <mailto:jmap-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/jmap/>
List-Post: <mailto:jmap@ietf.org>
List-Help: <mailto:jmap-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/jmap>, <mailto:jmap-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 12 Apr 2023 08:16:50 -0000

Just one more thing:

On Wed, Apr 12, 2023, at 10:07 AM, Robert Stepanek wrote:
> I suggest you change the value of parsed to a map of list of events, such as  `parsed: Id[CalendarEvent[]]`.

I say that albeit the current Cyrus IMAP implementation of CalendarEvent/parse also does this differently. It returns a single value rather than a list of values. If the iCalendar data can be converted to a single `CalendarEvent`, then this event is the return value. If not, the value is a single JSCalendar group object where the `entries` property contains a list of `CalendarEvents`. If you think that's a hack, that's because it really is.

I still think that my suggestion of always returning a list value above is the saner choice.