From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Alex =?utf-8?Q?Benn=C3=A9e?= Newsgroups: gmane.emacs.devel Subject: Re: changes to message-send-and-exit in Emacs 26 Date: Sat, 30 Sep 2017 03:11:56 +0100 Message-ID: <87a81dc4ur.fsf@linaro.org> References: <87h8vmd5s0.fsf@linaro.org> <83lgkx796o.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1506737927 2076 195.159.176.226 (30 Sep 2017 02:18:47 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 30 Sep 2017 02:18:47 +0000 (UTC) User-Agent: mu4e 0.9.19; emacs 26.0.60 Cc: "Dirk-Jan C. Binnema" , emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Sep 30 04:18:37 2017 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dy7MS-0007nT-0Q for ged-emacs-devel@m.gmane.org; Sat, 30 Sep 2017 04:18:36 +0200 Original-Received: from localhost ([::1]:37832 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dy7MV-0001Su-Q1 for ged-emacs-devel@m.gmane.org; Fri, 29 Sep 2017 22:18:39 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50029) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dy7G9-0004nq-Aq for emacs-devel@gnu.org; Fri, 29 Sep 2017 22:12:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dy7G6-0007rt-3y for emacs-devel@gnu.org; Fri, 29 Sep 2017 22:12:05 -0400 Original-Received: from mail-wm0-x22e.google.com ([2a00:1450:400c:c09::22e]:52179) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dy7G5-0007pm-TR for emacs-devel@gnu.org; Fri, 29 Sep 2017 22:12:02 -0400 Original-Received: by mail-wm0-x22e.google.com with SMTP id i131so2250290wma.0 for ; Fri, 29 Sep 2017 19:11:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=references:user-agent:from:to:cc:subject:in-reply-to:date :message-id:mime-version:content-transfer-encoding; bh=HHwUQkzrwYiqEZeyRqhmdX1elZSd7wJGoaiKnXf6UTQ=; b=Cah4UtkD5yidxXOZ4etAbMqAqKhESlQjs9IOargv1hFqpWczpWZ+WHO+SIogjN+4xA zUd5I4BusfF/rf0PswYbgO8fLpiKZYre1HsZLIQ3VfuLb4HEl1XCwZmc+tw1OaOWDU9e YKvsTI87Dp3PJPg3TnctbFVRVnDAOBNLPOgbY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:references:user-agent:from:to:cc:subject :in-reply-to:date:message-id:mime-version:content-transfer-encoding; bh=HHwUQkzrwYiqEZeyRqhmdX1elZSd7wJGoaiKnXf6UTQ=; b=bawYMXLvRsj7m2rkVBhUv7IqfRBwmdEyuJXKjTwA/708lt1ijk6u7irXhMl7DxpiE7 7+ufx0jXDj4ujeArTr3a3REcGr1g/VLTkbGzLFvP0GZXrq1kzGmwfmJrSdXkcWbM6gWX 4ls3NMMM8g9nW3wNUSql+3Vt7QCloZiEdKzGjfaRyQTPNkTiPEWUd/mi+RZZO1+8gjv7 saIGWrZGw/MaFN5zZrQnz9ecDjTO1XSFIho7Ji5dL9s8IDNaQsPNJMm8Udmj8F7isM29 jcgz/PScH1tIuvzxLMN/Q+CKlgl7EV6M4MlB0gEg6s+Pw5WdTdBSHx7lGOh14m2MiA5i aysg== X-Gm-Message-State: AMCzsaXmFQ10PBEEaS65w/iaEe4julxGZR4vZhV+nrFDLY9BEvuHP+6o Ibwn3dzqG9dyF6x+MFLcdfXggixrP4s= X-Google-Smtp-Source: AOwi7QBHxbt3y37vJR66FfgY0IiZ5NNwyYULfndNaZ1++ujrrfbn2OHDlO1As5pzAZYIJB6NNktQPQ== X-Received: by 10.28.54.133 with SMTP id y5mr2802744wmh.6.1506737518194; Fri, 29 Sep 2017 19:11:58 -0700 (PDT) Original-Received: from zen.linaro.local ([81.128.185.34]) by smtp.gmail.com with ESMTPSA id p80sm2795017wmf.42.2017.09.29.19.11.57 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 29 Sep 2017 19:11:57 -0700 (PDT) Original-Received: from zen (localhost [127.0.0.1]) by zen.linaro.local (Postfix) with ESMTPS id D32043E02BE; Sat, 30 Sep 2017 03:11:56 +0100 (BST) In-reply-to: <83lgkx796o.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:400c:c09::22e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:218955 Archived-At: Eli Zaretskii writes: >> From: Alex Bennée >> Date: Thu, 28 Sep 2017 19:42:07 +0100 >> >> I'm trying to track down what is happening in Emacs when I call >> message-send-and-exit to send an email from mu4e. I mailed emacs-user: >> >> Subject: Changes to message-mode and encoding in Emacs26 >> Date: Tue, 26 Sep 2017 16:41:03 +0100 >> Message-ID: <87tvzpcvsg.fsf@linaro.org> >> >> but I suspect the details of encoding need some input from developers. >> So in brief why does the act of sending an email result in: >> >> character: é (displayed as é) (codepoint 233, #o351, #xe9) >> preferred charset: unicode-bmp (Unicode Basic Multilingual Plane (U+0000..U+FFFF)) >> code point in charset: 0xE9 >> script: latin >> syntax: w which means: word >> category: .:Base, L:Left-to-right (strong), c:Chinese, j:Japanese, l:Latin, v:Viet >> to input: type "C-x 8 RET e9" or "C-x 8 RET LATIN SMALL LETTER E WITH ACUTE" >> buffer code: #xC3 #xA9 >> file code: #xC3 #xA9 (encoded by coding system utf-8-unix) >> display: terminal code #xC3 #xA9 >> >> ending up as: >> >> character: (displayed as ) (codepoint 4194243, #o17777703, #x3fffc3) >> preferred charset: eight-bit (Raw bytes 128-255) >> code point in charset: 0xC3 >> syntax: w which means: word >> category: L:Left-to-right (strong) >> to input: type "C-x 8 RET 3fffc3" >> buffer code: #xC3 >> file code: not encodable by coding system utf-8-unix >> display: not encodable for terminal >> >> Any pointers? > > I'm guessing that message-send-and-exit calls message-send in this > case. Then my suggestion would be to step through that function in > Edebug and see how the message text is communicated to mu4e and how it > is encoded in the process. Looking at Alexis' follow-up link I suspect the bug described in: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=25645 Looking at the backtrace there it looks like mu4e is involved in the Fcc handling to ensure the sent email ends up in the right Maildir after it is sent. Looking at the mu4e code it looks like it hooks into message-send-hook but weirdly as I compose this reply this doesn't seem to be set. > In general, I'd suggest to bring some mu4e developer on board of this > discussion, and ask them to describe how mu4e plugs into > message-send-and-exit. I've CC'd Dirk who may be able to shed more like on the hooks into message-send. Looking at the Fcc code it doesn't look like it does anything funky to the encoding although it does trigger a (write-file) after adding the Fcc header. -- Alex Bennée