GNU bug report logs - #38335
Emacs term: bracketed paste not supported

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Reported by: Gang Liang <randomizedthinking@HIDDEN>; Keywords: unreproducible; dated Fri, 22 Nov 2019 23:07:03 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.
Added tag(s) unreproducible. Request was from Lars Ingebrigtsen <larsi@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at 38335 <at> debbugs.gnu.org:


Received: (at 38335) by debbugs.gnu.org; 23 Nov 2019 12:17:07 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Nov 23 07:17:07 2019
Received: from localhost ([127.0.0.1]:55888 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1iYUKp-0003Q3-2T
	for submit <at> debbugs.gnu.org; Sat, 23 Nov 2019 07:16:20 -0500
Received: from quimby.gnus.org ([95.216.78.240]:35196)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1iYUKc-0003Ox-Jm
 for 38335 <at> debbugs.gnu.org; Sat, 23 Nov 2019 07:16:10 -0500
Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=marnie)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1iYUKU-000577-EX; Sat, 23 Nov 2019 13:16:00 +0100
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Gang Liang <randomizedthinking@HIDDEN>
Subject: Re: bug#38335: Emacs term: bracketed paste not supported
References: <CACs1p2QGz_kMjP1UK8rEMogi_+rBTurJXaFdiUW7P7gVE_eWYA@HIDDEN>
Date: Sat, 23 Nov 2019 13:15:57 +0100
In-Reply-To: <CACs1p2QGz_kMjP1UK8rEMogi_+rBTurJXaFdiUW7P7gVE_eWYA@HIDDEN>
 (Gang Liang's message of "Fri, 22 Nov 2019 15:01:54 -0800")
Message-ID: <87eexypz42.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview: Gang Liang <randomizedthinking@HIDDEN> writes: > Bracketed
 paste is well supported in emacs, yet not in the term > buffer. The reason
 I assume is that the terminal buffers need to be > processed differently
 that special escape sequences need to be [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 0.0 URIBL_BLOCKED          ADMINISTRATOR NOTICE: The query to URIBL was
 blocked.  See
 http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block
 for more information. [URIs: ingebrigtsen.no]
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 38335
Cc: 38335 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Gang Liang <randomizedthinking@HIDDEN> writes:

> Bracketed paste is well supported in emacs, yet not in the term
> buffer. The reason I assume is that the terminal buffers need to be
> processed differently that special escape sequences need to be sent to
> the underlying process, so the program running inside a term buffer
> can tell the difference between manual typing and pasting.
>
> Steps to reproduce the issue:
>
> 1. M-x term
> 2. run python (or any program which differentiates typing from pasting)
> 3. paste some codes with indentation into the python
> 4. verify the indentation is messed up

You don't say what Emacs version you're using (please use M-x
report-emacs-bug when reporting Emacs bugs), and I'm not sure what you
mean by "run python", but I tried `M-x term RET python RET' and then
pasted the following with mouse-2 into the buffer, and the indentation
seems correct?

So I'm not able to reproduce the bug.  Are there some additional steps
necessary to reproduce?

larsi@marnie:~/src/mplayer/ffmpeg/tools$ python
Python 2.7.16 (default, Oct 10 2019, 22:02:15) 
[GCC 8.3.0] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys, subprocess
>>> 
>>> if len(sys.argv) > 2:
...     ifile  = sys.argv[1]
...     encopt = sys.argv[2:-1]
...     ofile  = sys.argv[-1]
... else:
...     print 'usage: %s <input> [encode_options] <output>' % sys.argv[0]
...     sys.exit(1)
... 
usage:  <input> [encode_options] <output>
larsi@marnie:~/src/mplayer/ffmpeg/tools$ 

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#38335; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 22 Nov 2019 23:06:58 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Nov 22 18:06:58 2019
Received: from localhost ([127.0.0.1]:55693 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1iYI0u-00074S-Ry
	for submit <at> debbugs.gnu.org; Fri, 22 Nov 2019 18:06:58 -0500
Received: from lists.gnu.org ([209.51.188.17]:43831)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <randomizedthinking@HIDDEN>) id 1iYHwW-0006y6-Mh
 for submit <at> debbugs.gnu.org; Fri, 22 Nov 2019 18:02:24 -0500
Received: from eggs.gnu.org ([2001:470:142:3::10]:47143)
 by lists.gnu.org with esmtp (Exim 4.90_1)
 (envelope-from <randomizedthinking@HIDDEN>) id 1iYHwV-00060r-Kr
 for bug-gnu-emacs@HIDDEN; Fri, 22 Nov 2019 18:02:24 -0500
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM
 autolearn=disabled version=3.3.2
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <randomizedthinking@HIDDEN>) id 1iYHwU-0004vB-Pg
 for bug-gnu-emacs@HIDDEN; Fri, 22 Nov 2019 18:02:23 -0500
Received: from mail-ot1-x343.google.com ([2607:f8b0:4864:20::343]:33645)
 by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
 (Exim 4.71) (envelope-from <randomizedthinking@HIDDEN>)
 id 1iYHwU-0004uk-LN
 for bug-gnu-emacs@HIDDEN; Fri, 22 Nov 2019 18:02:22 -0500
Received: by mail-ot1-x343.google.com with SMTP id q23so1792963otn.0
 for <bug-gnu-emacs@HIDDEN>; Fri, 22 Nov 2019 15:02:19 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=mime-version:from:date:message-id:subject:to;
 bh=ig1JMBsdyItPx/Uh9mm8R+RovCmfsYNXNOLgzxG5OG0=;
 b=cq6FfXXnxOX5ybsLqp1re7KtyJBO1lmRfoSJlHVpqHAhyF+1d1+Chonv5TCChqOQMe
 0HrdUPYcLXPmiDc6E8N8sS43Hg4KGWJq5Xs0Pv7ds6zJQWeEmMlA+AJL7Aa+4K5HGqer
 C2xalDnxnEgDRhGSLmROOlP2OxnRIPFAwjSo7Xa+8PWTShNb1HTuGK6GOjWfBDzC4Qp1
 iaAb5av4tli8+RaqobtDy4BoSucTNFbe0f8WE0UALDQQtkpjz0Tbnhh9gPra2pXLf+xQ
 /QYd2KgSW7RJIaqKQVGNgZHa/YgzXL6kLZDYIzH39qbJVXn4NK3KUBSUPLy8og94EEo2
 qGhQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:mime-version:from:date:message-id:subject:to;
 bh=ig1JMBsdyItPx/Uh9mm8R+RovCmfsYNXNOLgzxG5OG0=;
 b=augAJ4WlwibXiyj182v7gSK2iZWcHraPgwtcxETYY1Inn4KIce0E8B4FIoIznU/s8B
 9JNI53TWlxXYo+UmocW5ocG4+8BaVUsL4ME88qaWsguWJrNyhZ1/lfFku/CKIlLtSmo7
 D+cNu/DMFbodlrfE/4bzzZnpv4VyOvCbFXJpVyZOMZ6Mj1beY4WovUMWiBtnKxHNL9Gt
 hx0xgQI5Re3EN76jouQT/KGiCjDOvJ/r+X8PlLoT4jWEC/ZXrR9LVayY2cmK01/9YyOv
 YVVfWUQTuiu4/+5vNJzz3+pdgIb2P2vY4121rEbU7X8qSFRniTw1U31rOiWccqLOn7Mm
 l2NQ==
X-Gm-Message-State: APjAAAX2R8L8G/2zSBycJUZDmZsikXdzEwLS6/7eWQ6c28xWowZ5o3V8
 nLFrqc5mC9RjcYyOARuMRlFSmKZP96nUF4M1jyvgMj6k
X-Google-Smtp-Source: APXvYqxgFTrn37DWfM4zZJiY55OUCNNDz6Ddv033QQl0IWQIItAXQPKjfEadp9632M0qdcGep2tghKya/ilF5Xd6A8I=
X-Received: by 2002:a05:6830:110e:: with SMTP id
 w14mr12152051otq.137.1574463738063; 
 Fri, 22 Nov 2019 15:02:18 -0800 (PST)
MIME-Version: 1.0
From: Gang Liang <randomizedthinking@HIDDEN>
Date: Fri, 22 Nov 2019 15:01:54 -0800
Message-ID: <CACs1p2QGz_kMjP1UK8rEMogi_+rBTurJXaFdiUW7P7gVE_eWYA@HIDDEN>
Subject: Emacs term: bracketed paste not supported
To: bug-gnu-emacs@HIDDEN
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
 recognized.
X-Received-From: 2607:f8b0:4864:20::343
X-Spam-Score: 0.7 (/)
X-Debbugs-Envelope-To: submit
X-Mailman-Approved-At: Fri, 22 Nov 2019 18:06:55 -0500
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.3 (--)

Bracketed paste is well supported in emacs, yet not in the term
buffer. The reason I assume is that the terminal buffers need to be
processed differently that special escape sequences need to be sent to
the underlying process, so the program running inside a term buffer
can tell the difference between manual typing and pasting.

Steps to reproduce the issue:

1. M-x term
2. run python (or any program which differentiates typing from pasting)
3. paste some codes with indentation into the python
4. verify the indentation is messed up




Acknowledgement sent to Gang Liang <randomizedthinking@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#38335; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Mon, 25 Nov 2019 12:00:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.