From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Federico Beffa Newsgroups: gmane.emacs.bugs Subject: bug#18052: 24.3; python.el and ipython shell Date: Fri, 18 Jul 2014 18:38:11 +0200 Message-ID: References: <83tx6e69ra.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: ger.gmane.org 1405701572 26640 80.91.229.3 (18 Jul 2014 16:39:32 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 18 Jul 2014 16:39:32 +0000 (UTC) Cc: 18052@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Jul 18 18:39:27 2014 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 1X8BBj-00047s-VB for geb-bug-gnu-emacs@m.gmane.org; Fri, 18 Jul 2014 18:39:16 +0200 Original-Received: from localhost ([::1]:50832 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X8BBj-0004QH-HH for geb-bug-gnu-emacs@m.gmane.org; Fri, 18 Jul 2014 12:39:15 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42488) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X8BBb-0004Mv-Sc for bug-gnu-emacs@gnu.org; Fri, 18 Jul 2014 12:39:12 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1X8BBX-0007PA-AG for bug-gnu-emacs@gnu.org; Fri, 18 Jul 2014 12:39:07 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:35048) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X8BBX-0007P6-73 for bug-gnu-emacs@gnu.org; Fri, 18 Jul 2014 12:39:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1X8BBW-0002Rd-Mx for bug-gnu-emacs@gnu.org; Fri, 18 Jul 2014 12:39:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Federico Beffa Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 18 Jul 2014 16:39:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18052 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 18052-submit@debbugs.gnu.org id=B18052.14057015099332 (code B ref 18052); Fri, 18 Jul 2014 16:39:02 +0000 Original-Received: (at 18052) by debbugs.gnu.org; 18 Jul 2014 16:38:29 +0000 Original-Received: from localhost ([127.0.0.1]:58547 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1X8BAv-0002QL-QN for submit@debbugs.gnu.org; Fri, 18 Jul 2014 12:38:29 -0400 Original-Received: from mail-lb0-f182.google.com ([209.85.217.182]:45366) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1X8BAo-0002Pr-MA for 18052@debbugs.gnu.org; Fri, 18 Jul 2014 12:38:22 -0400 Original-Received: by mail-lb0-f182.google.com with SMTP id z11so3053594lbi.13 for <18052@debbugs.gnu.org>; Fri, 18 Jul 2014 09:38:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=5GUGIehjLTUdKOZz0WazpmoXV1K/zblBmu3v/dB75tA=; b=zTTiJCCDeAmCzNJ76M2NEYaFtmRomB4kE8LvwvRpIAogHVSJydKhgL+TDdJrA+pMIi sAZfjvH6be3pldmf+VmvZAwT1Of4Vhv5K76cgeCJFSz7YrX46HkrHFRg9VTJOVosnFS6 K/mVblMWWTcF8HS1cnA1WC5a81/XHY6CO1wwNkuEDPXF28uC4s89sp/R6lGL1RcU/R0T 8ECyACp5/QrbulLebsSlA5/NuCmI1kzj9+zQvG8Jd8yLWXRXkXJ3p8WFToZ5rvJ9hzin 2sYmpy4cI1KYV5qRbvczr+xbg0UilbHj/cVtQ8c/H45O42O3wmcJMJrE5/c3XwNTBJ4C i1Ow== X-Received: by 10.152.207.36 with SMTP id lt4mr6724671lac.72.1405701491108; Fri, 18 Jul 2014 09:38:11 -0700 (PDT) Original-Received: by 10.114.18.44 with HTTP; Fri, 18 Jul 2014 09:38:11 -0700 (PDT) In-Reply-To: <83tx6e69ra.fsf@gnu.org> X-Google-Sender-Auth: pKszJAkSg12jvOItI3WqWei-Odc X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.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-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:91640 Archived-At: I've looked in the ipython configuration file, but have not seen anything. Do you have any suggestion on where to look further? On Fri, Jul 18, 2014 at 4:07 PM, Eli Zaretskii wrote: >> Date: Fri, 18 Jul 2014 15:51:47 +0200 >> From: Federico Beffa >> >> I'm trying to use the ipython shell from within emacs. To do so I've >> followed the instructions at the top of python.el and added the >> following code to my .emacs: >> >> (setq >> python-shell-interpreter "C:/Anaconda/python.exe" >> python-shell-interpreter-args >> "-i C:/Anaconda/Scripts/ipython-script.py console --matplotlib=qt" >> python-shell-prompt-regexp "In \\[[0-9]+\\]: " >> python-shell-prompt-output-regexp "Out\\[[0-9]+\\]: " >> python-shell-completion-setup-code >> "from IPython.core.completerlib import module_completion" >> python-shell-completion-module-string-code >> "';'.join(module_completion('''%s'''))\n" >> python-shell-completion-string-code >> "';'.join(get_ipython().Completer.all_completions('''%s'''))\n") >> >> When I execute (M-x) run-python, SOMETIMES the session does not >> initialize properly and the new buffer looks like this: >> >> ----------------------------------------------------------- >> Python 2.7.6 |Anaconda 2.0.1 (64-bit)| (default, Nov 11 2013, >> 10:49:15) [MSC v.1500 64 bit (AMD64)] >> Type "copyright", "credits" or "license" for more information. >> >> IPython 2.1.0 -- An enhanced Interactive Python. >> Anaconda is brought to you by Continuum Analytics. >> Please check out: http://continuum.io/thanks and https://binstar.org >> ? -> Introduction and overview of IPython's features. >> %quickref -> Quick reference. >> help -> Python's own help system. >> object? -> Details about 'object', use 'object??' for extra details. >> >> In [1]: >> ----------------------------------------------------------- >> >> The difference compared to the situation when everything is well, is >> that here I only see "In [1]:", while normally I should see 4 empty >> input prompts, with the last one reading "In [4]". When I execute any >> command such as "1+1" and press RET, nothing happens. >> >> This happens starting emacs with the -Q option and executing the ipython >> customization in the *scratch* buffer. > > Did you try to explore the possibility that this is caused by > buffering? Pipes on Windows are fully buffered, not line-buffered as > on Posix systems. If there's some way to control buffering from the > Python side, I suggest to try that, perhaps it will fix the problem.