From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: jay malby Newsgroups: gmane.emacs.bugs Subject: bug#23678: 24.5; Python auto-completion breaks inferior-python mode Date: Wed, 1 Jun 2016 18:31:55 -0400 Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001a1144b1d0b2d99c05343f0ff3 X-Trace: ger.gmane.org 1464820883 26895 80.91.229.3 (1 Jun 2016 22:41:23 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 1 Jun 2016 22:41:23 +0000 (UTC) To: 23678@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Jun 02 00:41:14 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1b8Ep6-0000ui-El for geb-bug-gnu-emacs@m.gmane.org; Thu, 02 Jun 2016 00:41:12 +0200 Original-Received: from localhost ([::1]:44425 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b8Ep5-00069O-PM for geb-bug-gnu-emacs@m.gmane.org; Wed, 01 Jun 2016 18:41:11 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:44308) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b8Eoz-000698-Ez for bug-gnu-emacs@gnu.org; Wed, 01 Jun 2016 18:41:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b8Eow-0000Ns-Vo for bug-gnu-emacs@gnu.org; Wed, 01 Jun 2016 18:41:04 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:37910) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b8Eow-0000No-RV for bug-gnu-emacs@gnu.org; Wed, 01 Jun 2016 18:41:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1b8Eow-0003SF-Le for bug-gnu-emacs@gnu.org; Wed, 01 Jun 2016 18:41:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: jay malby Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 01 Jun 2016 22:41:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 23678 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.146482080213186 (code B ref -1); Wed, 01 Jun 2016 22:41:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 1 Jun 2016 22:40:02 +0000 Original-Received: from localhost ([127.0.0.1]:50247 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1b8Enx-0003QR-Ok for submit@debbugs.gnu.org; Wed, 01 Jun 2016 18:40:02 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:49703) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1b8Egd-0003G3-Bl for submit@debbugs.gnu.org; Wed, 01 Jun 2016 18:32:27 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b8EgW-0005KA-TH for submit@debbugs.gnu.org; Wed, 01 Jun 2016 18:32:22 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:42257) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b8EgW-0005Jy-QS for submit@debbugs.gnu.org; Wed, 01 Jun 2016 18:32:20 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:40664) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b8EgT-0004Kt-Vv for bug-gnu-emacs@gnu.org; Wed, 01 Jun 2016 18:32:19 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b8EgR-0005JS-Ez for bug-gnu-emacs@gnu.org; Wed, 01 Jun 2016 18:32:16 -0400 Original-Received: from mail-it0-x244.google.com ([2607:f8b0:4001:c0b::244]:34180) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b8EgR-0005JM-8K for bug-gnu-emacs@gnu.org; Wed, 01 Jun 2016 18:32:15 -0400 Original-Received: by mail-it0-x244.google.com with SMTP id k76so1348622ita.1 for ; Wed, 01 Jun 2016 15:32:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to; bh=bGaZYqD+pJgyxh0BaL4C8hxO+IZM9t+Auni0cDaibmE=; b=THXd4vQzymLtFO7JiPAreLMjrOMOKSWcJhVsCGZBfl5VzLVEmuzuTR+a7CxIIGPX7I 4rE9h90Cyfx8bSM9o4dHv7T9iQ2yVonsQK3QtQMeCkfU4IgTn2KlBqE2cFgQOYTV2V1J fJyLlg8niaFqV3zng1r1spqRwVY+EJHfHwawq19Kf0fzKqrcqCB5occDqMwzaQCzUzFC R2BDdA7/O3Jq3DHJiHPcmhEktnQLuqDHIqBIcajpbN1aAp4JJNHZIgKWnlYP2hccXQV1 QKlJHMwFu76dSG+q51YuXizSq+KYNC+9fd9g4cYyI+FLf4nqd5LROWPZaJ5bQMLXCb7v Xbgw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=bGaZYqD+pJgyxh0BaL4C8hxO+IZM9t+Auni0cDaibmE=; b=D+yz0rDofaibt8Dm4w7vjlphcTpf8s1ciukLrAy12LSM8Q/vJr9vmuNbGUEmX+lkKW upBslujWOYebqjXABllm0xVCTLAkGrOt2cCoVwzS/s/tLUtsd04wdHDv6FFqbYSjXgRz MZWlWCbIIU0ayAx5J1F24WtPLq0vSGX+S8p71vSfZvHlo2uZ9sC/qZm0SnY6v6KrbmTP QNYsnnJJDpfeRwE95H9DDp1W3v6c0Q+I7SJTFNSk3s4Ln2EFe+NcrFI2EnToddzJnZ94 d18ONSs1w4XkzywKhEH6Zn05AgrdeDyaBh2ZZ7vDX0fa8TdOZz+zDhsg4vzI1oNdpAVX F5RQ== X-Gm-Message-State: ALyK8tLXLAWOVTJB3UcNPKJ3GP5Dj3DdgWA+F8wsR0RTepb6vWOdjMYPxNEfXOer+A2U9uc7ta1+G5IEqWDxCA== X-Received: by 10.36.2.71 with SMTP id 68mr387748itu.38.1464820334513; Wed, 01 Jun 2016 15:32:14 -0700 (PDT) Original-Received: by 10.107.135.208 with HTTP; Wed, 1 Jun 2016 15:31:55 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Mailman-Approved-At: Wed, 01 Jun 2016 18:40:00 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:118959 Archived-At: --001a1144b1d0b2d99c05343f0ff3 Content-Type: text/plain; charset=UTF-8 When running a python interpreter in inferior-python mode, sometimes calling auto-completion with C-M-i on an indented line causes the underlying python interpreter to get confused, leading it to produce an unexpected indent error. Steps to reproduce: 1. Start emacs with a blank config 2. run-python 3. run this code, performing auto-completion (C-M-i) between the "5" and ":" on line 2: for i in range(10): if i < 5: print(i) Python will break after hitting enter on the second line, reporting an unexpected indent. The same code without the C-M-i will run fine, printing the integers between 0 and 4 (inclusive). In GNU Emacs 24.5.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.20.3) of 2016-05-05 on arojas Windowing system distributor `The X.Org Foundation', version 11.0.11803000 System Description: Arch Linux Configured using: `configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib --localstatedir=/var --with-x-toolkit=gtk3 --with-xft 'CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong' CPPFLAGS=-D_FORTIFY_SOURCE=2 LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro' Important settings: value of $LANG: en_US.UTF-8 locale-coding-system: utf-8-unix Major mode: Inferior Python Minor modes in effect: compilation-shell-minor-mode: t tooltip-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Recent messages: Starting Emacs daemon. When done with this frame, type C-x 5 0 Making python-shell-interpreter local to *Python* while let-bound! Making python-shell-interpreter-args local to *Python* while let-bound! Sent python-shell-completion-setup-code Sent python-ffap-setup-code Sent python-eldoc-setup-code No match Load-path shadows: None found. Features: (shadow sort gnus-util mail-extr emacsbug message idna format-spec rfc822 mml mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util help-fns mail-prsvr mail-utils compile cl-extra python easymenu json comint ring cl-loaddefs cl-lib ansi-color server time-date tooltip electric uniquify ediff-hook vc-hooks lisp-float-type mwheel x-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list newcomment lisp-mode prog-mode register page menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer nadvice loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote make-network-process dbusbind gfilenotify dynamic-setting system-font-setting font-render-setting move-toolbar gtk x-toolkit x multi-tty emacs) Memory information: ((conses 16 84389 8157) (symbols 48 18864 0) (miscs 40 56 174) (strings 32 13129 4758) (string-bytes 1 399070) (vectors 16 10809) (vector-slots 8 401723 6355) (floats 8 73 175) (intervals 56 270 0) (buffers 960 13) (heap 1024 37934 927)) --001a1144b1d0b2d99c05343f0ff3 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
When running a python interpreter in inferior-python mode,=
sometimes calling auto-completion with C-M-i on an indented
line cau= ses the underlying python interpreter to get confused,
leading it to pro= duce an unexpected indent error.

Steps to reproduce:
1. Start ema= cs with a blank config
2. run-python
3. run this code, performing aut= o-completion (C-M-i) between the "5"
and ":" on line= 2:
for i in range(10):
=C2=A0 if=C2=A0 i < 5:
=C2=A0=C2=A0=C2= =A0 print(i)

Python will break after hitting enter on the second lin= e, reporting an
unexpected indent. The same code without the C-M-i will = run fine,
printing the integers between 0 and 4 (inclusive).


=
In GNU Emacs 24.5.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.20.3)
= =C2=A0of 2016-05-05 on arojas
Windowing system distributor `The X.Org Fo= undation', version 11.0.11803000
System Description:=C2=A0=C2=A0=C2= =A0 Arch Linux

Configured using:
=C2=A0`configure --prefix=3D/usr= --sysconfdir=3D/etc --libexecdir=3D/usr/lib
=C2=A0--localstatedir=3D/va= r --with-x-toolkit=3Dgtk3 --with-xft
=C2=A0'CFLAGS=3D-march=3Dx86-64= -mtune=3Dgeneric -O2 -pipe
=C2=A0-fstack-protector-strong' CPPFLAGS= =3D-D_FORTIFY_SOURCE=3D2
=C2=A0LDFLAGS=3D-Wl,-O1,--sort-common,--as-need= ed,-z,relro'

Important settings:
=C2=A0 value of $LANG: en_US= .UTF-8
=C2=A0 locale-coding-system: utf-8-unix

Major mode: Inferi= or Python

Minor modes in effect:
=C2=A0 compilation-shell-minor-m= ode: t
=C2=A0 tooltip-mode: t
=C2=A0 electric-indent-mode: t
=C2= =A0 mouse-wheel-mode: t
=C2=A0 tool-bar-mode: t
=C2=A0 menu-bar-mode:= t
=C2=A0 file-name-shadow-mode: t
=C2=A0 global-font-lock-mode: t=C2=A0 font-lock-mode: t
=C2=A0 auto-composition-mode: t
=C2=A0 auto= -encryption-mode: t
=C2=A0 auto-compression-mode: t
=C2=A0 line-numbe= r-mode: t
=C2=A0 transient-mark-mode: t

Recent messages:
Start= ing Emacs daemon.
When done with this frame, type C-x 5 0
Making pyth= on-shell-interpreter local to *Python* while let-bound!
Making python-sh= ell-interpreter-args local to *Python* while let-bound!
Sent python-shel= l-completion-setup-code
Sent python-ffap-setup-code
Sent python-eldoc= -setup-code
No match

Load-path shadows:
None found.

Fea= tures:
(shadow sort gnus-util mail-extr emacsbug message idna format-spe= c
rfc822 mml mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums
mm-= util help-fns mail-prsvr mail-utils compile cl-extra python easymenu
jso= n comint ring cl-loaddefs cl-lib ansi-color server time-date tooltip
ele= ctric uniquify ediff-hook vc-hooks lisp-float-type mwheel x-win x-dnd
to= ol-bar dnd fontset image regexp-opt fringe tabulated-list newcomment
lis= p-mode prog-mode register page menu-bar rfn-eshadow timer select
scroll-= bar mouse jit-lock font-lock syntax facemenu font-core frame cham
georgi= an utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao
korean japa= nese hebrew greek romanian slovak czech european ethiopic
indian cyrilli= c chinese case-table epa-hook jka-cmpr-hook help simple
abbrev minibuffe= r nadvice loaddefs button faces cus-face macroexp files
text-properties = overlay sha1 md5 base64 format env code-pages mule
custom widget hashtab= le-print-readable backquote make-network-process
dbusbind gfilenotify dy= namic-setting system-font-setting
font-render-setting move-toolbar gtk x= -toolkit x multi-tty emacs)

Memory information:
((conses 16 84389= 8157)
=C2=A0(symbols 48 18864 0)
=C2=A0(miscs 40 56 174)
=C2=A0(s= trings 32 13129 4758)
=C2=A0(string-bytes 1 399070)
=C2=A0(vectors 16= 10809)
=C2=A0(vector-slots 8 401723 6355)
=C2=A0(floats 8 73 175)=C2=A0(intervals 56 270 0)
=C2=A0(buffers 960 13)
=C2=A0(heap 1024 3= 7934 927))
--001a1144b1d0b2d99c05343f0ff3--