From unknown Thu Sep 11 20:36:39 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#8857 <8857@debbugs.gnu.org> To: bug#8857 <8857@debbugs.gnu.org> Subject: Status: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error Reply-To: bug#8857 <8857@debbugs.gnu.org> Date: Fri, 12 Sep 2025 03:36:39 +0000 retitle 8857 display-buffer attempt to pop-up frame in batch mode causes "U= nknown terminal type" error reassign 8857 emacs submitter 8857 Glenn Morris severity 8857 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Mon Jun 13 18:21:38 2011 Received: (at submit) by debbugs.gnu.org; 13 Jun 2011 22:21:38 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWFVp-0006Kv-Oi for submit@debbugs.gnu.org; Mon, 13 Jun 2011 18:21:38 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWFVo-0006Ki-I3 for submit@debbugs.gnu.org; Mon, 13 Jun 2011 18:21:37 -0400 Received: from localhost ([127.0.0.1]:43200) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWFVi-00030e-QK; Mon, 13 Jun 2011 18:21:30 -0400 From: Glenn Morris To: submit@debbugs.gnu.org Subject: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error X-Spook: Zachawi BRLO enemy of the state Bellcore corporate X-Ran: )!FcoYlRKdE|UuZkVfoE,Qj5K%PdCU$`.Vs]yv3z'O#]mCVLMa|@O\CAW#&!seH/471)lD X-Hue: blue X-Debbugs-No-Ack: yes X-Attribution: GM Date: Mon, 13 Jun 2011 18:21:30 -0400 Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.3 (------) Package: emacs With the current trunk: ./src/emacs -Q -batch README INSTALL Makefile Loading vc-bzr... Unknown terminal type (exits with status /= 0) OK, this is not a very sensible example, but it illustrates the point. It's caused by display-buffer trying to pop-up a frame in batch-mode and is very recent. Emacs 23 does not have this problem by default, but the following shows the same issue: emacs-23.3 -Q -batch --eval '(setq pop-up-frames t)' README INSTALL Makefile From debbugs-submit-bounces@debbugs.gnu.org Mon Jun 13 18:23:57 2011 Received: (at 8857) by debbugs.gnu.org; 13 Jun 2011 22:23:57 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWFY5-0006OK-26 for submit@debbugs.gnu.org; Mon, 13 Jun 2011 18:23:57 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWFXz-0006O3-VC for 8857@debbugs.gnu.org; Mon, 13 Jun 2011 18:23:56 -0400 Received: from localhost ([127.0.0.1]:43227) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWFXu-00034q-Au; Mon, 13 Jun 2011 18:23:46 -0400 From: Glenn Morris To: 8857@debbugs.gnu.org Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: X-Spook: UMTS New World Order anthrax terrorism Bellcore X-Ran: A^A<4tSeHP2i;q3(f]Kr03-s49pJ0g=uU,MagAlJYGeV.9-NadYm;7D*DHC!=zG-$:9~7[ X-Hue: red X-Debbugs-No-Ack: yes X-Attribution: GM Date: Mon, 13 Jun 2011 18:23:46 -0400 In-Reply-To: (Glenn Morris's message of "Mon, 13 Jun 2011 18:21:30 -0400") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: 8857 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.3 (------) PS I forgot to say that I think display-buffer should not try to pop-up frames (or do anything at all?) in batch-mode. Or if it must give an error it should try to give a more helpful one than "Unknown terminal type". From debbugs-submit-bounces@debbugs.gnu.org Tue Jun 14 05:16:25 2011 Received: (at 8857) by debbugs.gnu.org; 14 Jun 2011 09:16:25 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWPjV-00051J-59 for submit@debbugs.gnu.org; Tue, 14 Jun 2011 05:16:25 -0400 Received: from mailout-de.gmx.net ([213.165.64.23]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1QWPjT-000510-SI for 8857@debbugs.gnu.org; Tue, 14 Jun 2011 05:16:24 -0400 Received: (qmail invoked by alias); 14 Jun 2011 09:16:17 -0000 Received: from 62-47-57-173.adsl.highway.telekom.at (EHLO [62.47.57.173]) [62.47.57.173] by mail.gmx.net (mp025) with SMTP; 14 Jun 2011 11:16:17 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX18sA6Ax9OAsw+pPcn2VYiNphegCr643Qs4dfM/+d9 6oW9zw+THZiHyn Message-ID: <4DF726E0.6020205@gmx.at> Date: Tue, 14 Jun 2011 11:16:16 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) MIME-Version: 1.0 To: Glenn Morris Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Spam-Score: -2.5 (--) X-Debbugs-Envelope-To: 8857 Cc: 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.5 (--) > OK, this is not a very sensible example, but it illustrates the point. > It's caused by display-buffer trying to pop-up a frame in batch-mode and > is very recent. Can you tell me where and why `display-buffer' is called? > PS I forgot to say that I think display-buffer should not try to pop-up > frames (or do anything at all?) in batch-mode. Or if it must give an > error it should try to give a more helpful one than "Unknown terminal > type". In particular not with emacs -Q. But I have no experience debugging emacs with the batch option. So before delving into this maybe you could give me more information? Note that while `pop-up-frames' has the optional value graphic-only which should prevent Emacs from popping up frames on non-graphic systems, that value is consistently overridden by applications that bind `pop-up-frames' to t. But I don't think that's related. martin From debbugs-submit-bounces@debbugs.gnu.org Tue Jun 14 12:19:15 2011 Received: (at 8857) by debbugs.gnu.org; 14 Jun 2011 16:19:15 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWWKh-0007ZL-0S for submit@debbugs.gnu.org; Tue, 14 Jun 2011 12:19:15 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWWKe-0007Z8-JK for 8857@debbugs.gnu.org; Tue, 14 Jun 2011 12:19:13 -0400 Received: from localhost ([127.0.0.1]:45870) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWWKY-0002PB-Jw; Tue, 14 Jun 2011 12:19:06 -0400 From: Glenn Morris To: martin rudalics Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> X-Spook: 9705 Samford Road target SDI rs9512c JFK White Water ICE X-Ran: "=bTkE_m)fk>ciW]PDVnG"$nf=Wa%c=6=!R6$"'5F@.9Nn?Y^PJ+|V{q=A5^WNRSbBi[Xk X-Hue: black X-Debbugs-No-Ack: yes X-Attribution: GM Date: Tue, 14 Jun 2011 12:19:06 -0400 In-Reply-To: <4DF726E0.6020205@gmx.at> (martin rudalics's message of "Tue, 14 Jun 2011 11:16:16 +0200") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: 8857 Cc: 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.3 (------) martin rudalics wrote: >> OK, this is not a very sensible example, but it illustrates the point. >> It's caused by display-buffer trying to pop-up a frame in batch-mode and >> is very recent. > > Can you tell me where and why `display-buffer' is called? I don't know. From `find-file' I guess. I noticed because of this: http://lists.gnu.org/archive/html/emacs-buildstatus/2011-06/msg00004.html (which was due to custom-make-dependencies leaving files on the command-line so they were processed as normal file arguments) >> PS I forgot to say that I think display-buffer should not try to pop-up >> frames (or do anything at all?) in batch-mode. Or if it must give an >> error it should try to give a more helpful one than "Unknown terminal >> type". > > In particular not with emacs -Q. But I have no experience debugging > emacs with the batch option. So before delving into this maybe you > could give me more information? Maybe display-buffer should just be a no-op in batch-mode, since it's impossible (?) to display anything then (except via the echo area). (defun display-buffer () "" (unless noninteractive ...)) From debbugs-submit-bounces@debbugs.gnu.org Tue Jun 14 13:14:58 2011 Received: (at 8857) by debbugs.gnu.org; 14 Jun 2011 17:14:58 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWXCb-0000W4-Qi for submit@debbugs.gnu.org; Tue, 14 Jun 2011 13:14:58 -0400 Received: from mailout-de.gmx.net ([213.165.64.22]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1QWXCZ-0000Vj-Fe for 8857@debbugs.gnu.org; Tue, 14 Jun 2011 13:14:56 -0400 Received: (qmail invoked by alias); 14 Jun 2011 17:14:49 -0000 Received: from 62-47-43-63.adsl.highway.telekom.at (EHLO [62.47.43.63]) [62.47.43.63] by mail.gmx.net (mp048) with SMTP; 14 Jun 2011 19:14:49 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX19h2WNGPI1h2RipSdaol2sfqaZNQcQ6YwJbMkg6NX fEnjkOffBFfDDs Message-ID: <4DF79707.7000707@gmx.at> Date: Tue, 14 Jun 2011 19:14:47 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) MIME-Version: 1.0 To: Glenn Morris Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Spam-Score: -2.5 (--) X-Debbugs-Envelope-To: 8857 Cc: 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.5 (--) >> Can you tell me where and why `display-buffer' is called? > > I don't know. From `find-file' I guess. I noticed because of this: > > http://lists.gnu.org/archive/html/emacs-buildstatus/2011-06/msg00004.html > > (which was due to custom-make-dependencies leaving files on the > command-line so they were processed as normal file arguments) I see. But I wonder why this wasn't a problem before (that is, the idea of popping up a new frame). > Maybe display-buffer should just be a no-op in batch-mode, since it's > impossible (?) to display anything then (except via the echo area). > > (defun display-buffer () "" > (unless noninteractive > ...)) That would be trivial to do. martin From debbugs-submit-bounces@debbugs.gnu.org Tue Jun 14 13:20:20 2011 Received: (at 8857) by debbugs.gnu.org; 14 Jun 2011 17:20:20 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWXHn-0000fG-K2 for submit@debbugs.gnu.org; Tue, 14 Jun 2011 13:20:20 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWXHm-0000f5-I0 for 8857@debbugs.gnu.org; Tue, 14 Jun 2011 13:20:18 -0400 Received: from localhost ([127.0.0.1]:51371) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWXHg-0000Wi-DA; Tue, 14 Jun 2011 13:20:12 -0400 From: Glenn Morris To: martin rudalics Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> X-Spook: freedom monarchist RSA SRI PET number key Soviet Rumsfeld X-Ran: Ll]fu}];zVP5\dUnZV@;9pp#y;/,X!]1KQ%#'4}boCMi@5Y7-oTOfRy]4hPg=mCzl`^|r+ X-Hue: black X-Debbugs-No-Ack: yes X-Attribution: GM Date: Tue, 14 Jun 2011 13:20:11 -0400 In-Reply-To: <4DF79707.7000707@gmx.at> (martin rudalics's message of "Tue, 14 Jun 2011 19:14:47 +0200") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: 8857 Cc: 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.3 (------) martin rudalics wrote: > But I wonder why this wasn't a problem before (that is, the idea of > popping up a new frame). I guess because pop-up-frames defaults to nil in Emacs 23. But in the trunk, a default Emacs may now pop-up a frame if it thinks it necessary. From debbugs-submit-bounces@debbugs.gnu.org Tue Jun 14 13:56:42 2011 Received: (at 8857) by debbugs.gnu.org; 14 Jun 2011 17:56:42 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWXr0-0001WL-6D for submit@debbugs.gnu.org; Tue, 14 Jun 2011 13:56:42 -0400 Received: from mailout-de.gmx.net ([213.165.64.22]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1QWXqy-0001W8-6R for 8857@debbugs.gnu.org; Tue, 14 Jun 2011 13:56:41 -0400 Received: (qmail invoked by alias); 14 Jun 2011 17:56:34 -0000 Received: from 62-47-43-63.adsl.highway.telekom.at (EHLO [62.47.43.63]) [62.47.43.63] by mail.gmx.net (mp034) with SMTP; 14 Jun 2011 19:56:34 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX1+9P7gdWRS9J2go3AfET3SXng02bzJphg2Vss1yax XYEto384tgrdKx Message-ID: <4DF7A0D0.2030707@gmx.at> Date: Tue, 14 Jun 2011 19:56:32 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) MIME-Version: 1.0 To: Glenn Morris Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Spam-Score: -2.5 (--) X-Debbugs-Envelope-To: 8857 Cc: 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.5 (--) > I guess because pop-up-frames defaults to nil in Emacs 23. Emacs 23 could pop up new frame provided the selected frame isn't "usable". > But in the trunk, a default Emacs may now pop-up a frame if it thinks it > necessary. I only tried to mimic Emacs 23 here. So if the original frame cannot be used it does try to pop up a new one. Doesn't Emacs make an invisible frame in batch mode? Maybe the problem happens because I now load window.el _before_ files.el. So in Emacs 23 files.el maybe tried to display a buffer but failed silently. What happens generally in batch mode when you call `display-buffer', for example, during a backtrace? martin From debbugs-submit-bounces@debbugs.gnu.org Tue Jun 14 14:26:00 2011 Received: (at 8857) by debbugs.gnu.org; 14 Jun 2011 18:26:00 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWYJM-0002ER-6T for submit@debbugs.gnu.org; Tue, 14 Jun 2011 14:26:00 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWYJK-0002EF-8K for 8857@debbugs.gnu.org; Tue, 14 Jun 2011 14:25:58 -0400 Received: from localhost ([127.0.0.1]:39231) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWYJE-0004rh-Pk; Tue, 14 Jun 2011 14:25:52 -0400 From: Glenn Morris To: martin rudalics Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> X-Spook: investigation CDMA illuminati world domination top secret X-Ran: ;?h'hOiKU\CeX$N(z]mE9.+k,Dn%RkRi:3,_MGG9\#fs0:S0Luz{C!X?u`Iv6<6Wn;$3\2 X-Hue: yellow X-Debbugs-No-Ack: yes X-Attribution: GM Date: Tue, 14 Jun 2011 14:25:52 -0400 In-Reply-To: <4DF7A0D0.2030707@gmx.at> (martin rudalics's message of "Tue, 14 Jun 2011 19:56:32 +0200") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: 8857 Cc: 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.3 (------) martin rudalics wrote: >> I guess because pop-up-frames defaults to nil in Emacs 23. > > Emacs 23 could pop up new frame provided the selected frame isn't > "usable". I confess I did not look into precisely what Emacs 23 does, I just saw that pop-up-frames defaults to nil there. (See below.) >> But in the trunk, a default Emacs may now pop-up a frame if it thinks it >> necessary. > > I only tried to mimic Emacs 23 here. So if the original frame cannot be > used it does try to pop up a new one. Doesn't Emacs make an invisible > frame in batch mode? > > Maybe the problem happens because I now load window.el _before_ > files.el. So in Emacs 23 files.el maybe tried to display a buffer but > failed silently. I don't think that can be it. Here's what the addition of a simple: (message "%s:%s" buffer-or-name method) to display-buffer in the trunk shows: ./src/emacs -Q -batch README INSTALL BUGS INSTALL:reuse-window INSTALL:pop-up-window BUGS:reuse-window BUGS:pop-up-window BUGS:pop-up-frame Unknown terminal type Adding similar stuff to emacs-23, I see that display-buffer's cond tries the special-display-function branch (no match), the pop-up-windows branch (no window-to-use), and ends up in the last branch, where it finds a window-to-use every time. So it never tries to pop-up a frame. From debbugs-submit-bounces@debbugs.gnu.org Tue Jun 14 15:09:17 2011 Received: (at 8857) by debbugs.gnu.org; 14 Jun 2011 19:09:17 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWYzE-0003K3-Ud for submit@debbugs.gnu.org; Tue, 14 Jun 2011 15:09:17 -0400 Received: from mailout-de.gmx.net ([213.165.64.23]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1QWYzD-0003Jh-3e for 8857@debbugs.gnu.org; Tue, 14 Jun 2011 15:09:15 -0400 Received: (qmail invoked by alias); 14 Jun 2011 19:09:08 -0000 Received: from 62-47-43-63.adsl.highway.telekom.at (EHLO [62.47.43.63]) [62.47.43.63] by mail.gmx.net (mp043) with SMTP; 14 Jun 2011 21:09:08 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX19AVt4Jw5JAgpKTCHNIQO3R2RMWJZps1xG8AvfdGU 4CNeWpJLh9ZovR Message-ID: <4DF7B1D2.3010304@gmx.at> Date: Tue, 14 Jun 2011 21:09:06 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) MIME-Version: 1.0 To: Glenn Morris Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Spam-Score: -2.5 (--) X-Debbugs-Envelope-To: 8857 Cc: 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.5 (--) > Adding similar stuff to emacs-23, I see that display-buffer's cond tries > the special-display-function branch (no match), the pop-up-windows > branch (no window-to-use), and ends up in the last branch, where it > finds a window-to-use every time. So it never tries to pop-up a frame. Emacs 23 tries to pop up a frame only when the selected frame is a minibuffer frame. I shall add an appropriate condition in Emacs 24. martin From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 03:29:31 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 07:29:31 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWkXb-0003nc-Ct for submit@debbugs.gnu.org; Wed, 15 Jun 2011 03:29:31 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWkXZ-0003nR-6p for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 03:29:29 -0400 Received: from localhost ([127.0.0.1]:54302) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWkXT-0007ZK-CZ; Wed, 15 Jun 2011 03:29:23 -0400 From: Glenn Morris To: martin rudalics Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> X-Spook: arrangements basement Bush Wired Area 51 Elvis cypherpunk X-Ran: $._Zvjqu"I<_ezz}*+F've[gs8Ncp]&jhxZLp3}j[K@8Y2% User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: 8857 Cc: 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.3 (------) In addition I still think it might be worth explicitly making display-buffer a no-op in batch mode, unless someone can think of something it can actually do in such cases. I think this could only be by side effect. Eg, can it run hooks, and can those hooks be expected to do anything when there isn't actually a display? If not then it seems simpler and more efficient to not even try displaying buffers in batch mode (and less confusing, since it can give unclear errors trying to do something that cannot work). From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 04:02:11 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 08:02:11 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWl3D-0004XA-0H for submit@debbugs.gnu.org; Wed, 15 Jun 2011 04:02:11 -0400 Received: from mailout-de.gmx.net ([213.165.64.22]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1QWl3A-0004Wy-8J for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 04:02:09 -0400 Received: (qmail invoked by alias); 15 Jun 2011 08:02:01 -0000 Received: from 62-47-36-239.adsl.highway.telekom.at (EHLO [62.47.36.239]) [62.47.36.239] by mail.gmx.net (mp010) with SMTP; 15 Jun 2011 10:02:01 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX1/YCpF77NHY+qUlNCpjJlkRW2qlm5aXD4yKQSlv36 fYX4PZ0KyRl+bt Message-ID: <4DF866F7.3070006@gmx.at> Date: Wed, 15 Jun 2011 10:01:59 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) MIME-Version: 1.0 To: Glenn Morris Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> In-Reply-To: <9ypqmfy2lo.fsf@fencepost.gnu.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Spam-Score: -2.5 (--) X-Debbugs-Envelope-To: 8857 Cc: 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.5 (--) > In addition I still think it might be worth explicitly making > display-buffer a no-op in batch mode, unless someone can think of > something it can actually do in such cases. I think this could only be > by side effect. Eg, can it run hooks, and can those hooks be expected to > do anything when there isn't actually a display? > > If not then it seems simpler and more efficient to not even try > displaying buffers in batch mode (and less confusing, since it can give > unclear errors trying to do something that cannot work). There's a silent convention that `display-buffer' _always_ returns a window. If it doesn't in batch mode, code relying on that convention might break. I don't know how realistic such a scenario is, though. Meanwhile I checked in two fixes that should assure that `display-buffer' doesn't try to pop up a frame with emacs -Q. If they work, you should be able to remove your earlier hack. martin From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 10:37:05 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 14:37:05 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWrDM-0005bq-NT for submit@debbugs.gnu.org; Wed, 15 Jun 2011 10:37:05 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.181] helo=ironport2-out.pppoe.ca) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWrDK-0005aj-Lq for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 10:37:03 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av0EACnD+E1FpY1I/2dsb2JhbABSplB4iHO+eIYmBJ0/hBs X-IronPort-AV: E=Sophos;i="4.65,370,1304308800"; d="scan'208";a="116352561" Received: from 69-165-141-72.dsl.teksavvy.com (HELO ceviche.home) ([69.165.141.72]) by ironport2-out.pppoe.ca with ESMTP/TLS/ADH-AES256-SHA; 15 Jun 2011 10:36:57 -0400 Received: by ceviche.home (Postfix, from userid 20848) id C86E5660F1; Wed, 15 Jun 2011 11:36:56 -0300 (ART) From: Stefan Monnier To: Glenn Morris Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error Message-ID: References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> Date: Wed, 15 Jun 2011 10:36:56 -0400 In-Reply-To: <9ypqmfy2lo.fsf@fencepost.gnu.org> (Glenn Morris's message of "Wed, 15 Jun 2011 03:29:23 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.1 (--) X-Debbugs-Envelope-To: 8857 Cc: martin rudalics , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.1 (--) > In addition I still think it might be worth explicitly making > display-buffer a no-op in batch mode, unless someone can think of > something it can actually do in such cases. I think this could only be "batch mode" and "server mode" are *very* closely related. So I'd stay away from any attempt to special case "batch mode". At best, you could try and check the currently selected terminal and do something special when that terminal is the "initial" terminal (the one bound to stdout/stdin), but I'd rather not obscure the code to "optimize" this case. Stefan From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 12:17:26 2011 Received: (at 8857-done) by debbugs.gnu.org; 15 Jun 2011 16:17:26 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWsmU-0007rX-4r for submit@debbugs.gnu.org; Wed, 15 Jun 2011 12:17:26 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWsmR-0007rL-AF for 8857-done@debbugs.gnu.org; Wed, 15 Jun 2011 12:17:24 -0400 Received: from localhost ([127.0.0.1]:47192) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWsmL-0007so-OZ; Wed, 15 Jun 2011 12:17:17 -0400 From: Glenn Morris To: 8857-done@debbugs.gnu.org Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> X-Spook: CNCIS ammunition computer terrorism Elvis Commecen Hugo X-Ran: &%EljF'Jz\-f,%XMq%wY/Q$=:F?=B5Fo4Ogp*,> X-Hue: yellow X-Debbugs-No-Ack: yes X-Attribution: GM Date: Wed, 15 Jun 2011 12:17:17 -0400 In-Reply-To: <4DF866F7.3070006@gmx.at> (martin rudalics's message of "Wed, 15 Jun 2011 10:01:59 +0200") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -4.8 (----) X-Debbugs-Envelope-To: 8857-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.8 (----) Stefan Monnier wrote: > "batch mode" and "server mode" are *very* closely related. So I'd stay > away from any attempt to special case "batch mode". martin rudalics wrote: > There's a silent convention that `display-buffer' _always_ returns a > window. If it doesn't in batch mode, code relying on that convention > might break. I don't know how realistic such a scenario is, though. OK, no problem, let's not bother with it then. > Meanwhile I checked in two fixes that should assure that > `display-buffer' doesn't try to pop up a frame with emacs -Q. If they > work, you should be able to remove your earlier hack. If you mean the cus-dep thing, then it was a correct change, independent of this issue, and should remain. I'll close this, thanks. From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 13:02:20 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 17:02:20 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWtTv-0000U2-EH for submit@debbugs.gnu.org; Wed, 15 Jun 2011 13:02:19 -0400 Received: from v3-1008.vxen.de ([79.140.41.8]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWtTs-0000Tm-Mb for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 13:02:17 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=randomsample.de; s=a; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To:Subject:Cc:To:From; bh=gsTGD9ElHP9o7+h7McjN4v5R0d7F+UZJmWQBUCX2epU=; b=lMHuAwXhl+yYO+yztPlUwJiBKJ6EA5B+W9fubPIrKHcqvGSejOPsUSlfH3uLUtO/xu8Id2sF4XEWP7ar3yXtHt/3frnR+QLUi6A2qzwEtVG9623LyYP2YEqVtujMHW0O; Received: from dslc-082-083-039-127.pools.arcor-ip.net ([82.83.39.127] helo=spaten) by v3-1008.vxen.de with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1QWtTm-0007hi-Sx; Wed, 15 Jun 2011 19:02:10 +0200 From: David Engster To: martin rudalics Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error In-Reply-To: <4DF866F7.3070006@gmx.at> (martin rudalics's message of "Wed, 15 Jun 2011 10:01:59 +0200") References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> User-Agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (gnu/linux) Mail-Copies-To: never Date: Wed, 15 Jun 2011 19:01:12 +0200 Message-ID: <87oc1zkp0n.fsf@engster.org> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.8 (--) X-Debbugs-Envelope-To: 8857 Cc: Glenn Morris , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.8 (--) martin rudalics writes: > Meanwhile I checked in two fixes that should assure that > `display-buffer' doesn't try to pop up a frame with emacs -Q. If they > work, you should be able to remove your earlier hack. Is this supposed to also fix the problem for batch mode? Because I still see this error with revno. 104589: --> emacs --batch foo bar baz Unknown terminal type Actually, this currently breaks the CEDET build, because it uses a hack to provide arguments for functions called with the "-f" switch... -David From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 13:45:34 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 17:45:34 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWu9m-0001SE-Il for submit@debbugs.gnu.org; Wed, 15 Jun 2011 13:45:34 -0400 Received: from mailout-de.gmx.net ([213.165.64.22]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1QWu9j-0001Ry-VX for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 13:45:32 -0400 Received: (qmail invoked by alias); 15 Jun 2011 17:45:25 -0000 Received: from 62-47-44-36.adsl.highway.telekom.at (EHLO [62.47.44.36]) [62.47.44.36] by mail.gmx.net (mp014) with SMTP; 15 Jun 2011 19:45:25 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX19vz1Zw2I5vIyTWASlKb1BI5iNF71k4TSfyZ3sgq6 LNWZYoJCXhhKyf Message-ID: <4DF8EFB3.1060304@gmx.at> Date: Wed, 15 Jun 2011 19:45:23 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) MIME-Version: 1.0 To: David Engster Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> In-Reply-To: <87oc1zkp0n.fsf@engster.org> Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Spam-Score: -1.7 (-) X-Debbugs-Envelope-To: 8857 Cc: Glenn Morris , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.7 (-) > Is this supposed to also fix the problem for batch mode? Because I still > see this error with revno. 104589: It was supposed to fix that, yes. > --> emacs --batch foo bar baz > Unknown terminal type Can you check whether `display-buffer' tries to pop up a new buffer? I don't have the slightest experience running Emacs in batch mode. > Actually, this currently breaks the CEDET build, because it uses a hack > to provide arguments for functions called with the "-f" switch... Maybe Glenn can tell us what's going on? martin From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 14:09:15 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 18:09:15 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWuWg-0001yo-V5 for submit@debbugs.gnu.org; Wed, 15 Jun 2011 14:09:15 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWuWe-0001ya-TN for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 14:09:13 -0400 Received: from localhost ([127.0.0.1]:54795) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWuWZ-0006bb-0G; Wed, 15 Jun 2011 14:09:07 -0400 From: Glenn Morris To: martin rudalics Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF8EFB3.1060304@gmx.at> X-Spook: afsatcom ASLET Baranyi SDI PGP mania diwn AVIP X-Ran: r]C8/qt|pwZ|dWY4C5(mU4vFDWpOkVXq\bSz2S?q8b}_90!m)A#dK>2MZSCDINU(l;e$8y X-Hue: white X-Debbugs-No-Ack: yes X-Attribution: GM Date: Wed, 15 Jun 2011 14:09:05 -0400 In-Reply-To: <4DF8EFB3.1060304@gmx.at> (martin rudalics's message of "Wed, 15 Jun 2011 19:45:23 +0200") Message-ID: <36ips7otku.fsf@fencepost.gnu.org> User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: 8857 Cc: 8857@debbugs.gnu.org, David Engster X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.3 (------) martin rudalics wrote: > Maybe Glenn can tell us what's going on? Haha, nope, except to point out that you said: > Meanwhile I checked in two fixes that should assure that > `display-buffer' doesn't try to pop up a frame with emacs -Q. whereas the quoted recipe: >> --> emacs --batch foo bar baz >> Unknown terminal type does not use -Q. (Therefore I guess it would fail in the same way for anyone using Emacs 23 who happens to have set pop-up-frames = t in their .emacs.) From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 14:14:48 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 18:14:48 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWuc3-00026S-GT for submit@debbugs.gnu.org; Wed, 15 Jun 2011 14:14:47 -0400 Received: from v3-1008.vxen.de ([79.140.41.8]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWuc0-00026E-68 for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 14:14:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=randomsample.de; s=a; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To:Subject:Cc:To:From; bh=XR5Ibmwdni0+fJt/iBldWOyZ/SiNnFqGD8x02EKrVco=; b=Zaf0R3FUV2jQ0CyzPvHI5RD4AxUVj7byfNgfNzC9KQQmOKHPfkw5wMV6vq7+c/OhGdaHZSg98rVt5JgqIv9VS/RIFjX+fbrQv28SzM4kysR5Gzt5czDr1RIxoMk+vh68; Received: from dslc-082-083-039-127.pools.arcor-ip.net ([82.83.39.127] helo=spaten) by v3-1008.vxen.de with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1QWubt-0000Ha-Qr; Wed, 15 Jun 2011 20:14:37 +0200 From: David Engster To: Glenn Morris Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error In-Reply-To: <36ips7otku.fsf@fencepost.gnu.org> (Glenn Morris's message of "Wed, 15 Jun 2011 14:09:05 -0400") References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF8EFB3.1060304@gmx.at> <36ips7otku.fsf@fencepost.gnu.org> User-Agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (gnu/linux) Date: Wed, 15 Jun 2011 20:13:39 +0200 Message-ID: <87k4cnklnw.fsf@engster.org> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.8 (--) X-Debbugs-Envelope-To: 8857 Cc: martin rudalics , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.8 (--) Glenn Morris writes: > martin rudalics wrote: > >> Maybe Glenn can tell us what's going on? > > Haha, nope, except to point out that you said: > >> Meanwhile I checked in two fixes that should assure that >> `display-buffer' doesn't try to pop up a frame with emacs -Q. > > whereas the quoted recipe: > >>> --> emacs --batch foo bar baz >>> Unknown terminal type > > does not use -Q. It also fails with "-Q" (and "--batch" implies "-q", at least). Cheers, David From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 14:31:53 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 18:31:53 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWusb-0002Ug-0U for submit@debbugs.gnu.org; Wed, 15 Jun 2011 14:31:53 -0400 Received: from v3-1008.vxen.de ([79.140.41.8]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWusY-0002UP-Mu for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 14:31:51 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=randomsample.de; s=a; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To:Subject:Cc:To:From; bh=esJszfnHDuvc1TzMkoWqZUyO5AogA1YkL1uO8ELKQn8=; b=XNroMvQEUsFQsc3U6XLNOpvvea9BTm3HC5L+5d+aQf3y3GSJzGPrPysQhm9j8JWYpW3JmtuW1OppP60NTE7HdalvRFGZ3bRjxuNC/oId8+vKKyqBsaH2UrGAqSYkIsux; Received: from dslc-082-083-039-127.pools.arcor-ip.net ([82.83.39.127] helo=spaten) by v3-1008.vxen.de with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1QWusS-0000Su-E9; Wed, 15 Jun 2011 20:31:44 +0200 From: David Engster To: martin rudalics Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error In-Reply-To: <4DF8EFB3.1060304@gmx.at> (martin rudalics's message of "Wed, 15 Jun 2011 19:45:23 +0200") References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF8EFB3.1060304@gmx.at> User-Agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (gnu/linux) Date: Wed, 15 Jun 2011 20:30:46 +0200 Message-ID: <87fwnbkkvd.fsf@engster.org> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.8 (--) X-Debbugs-Envelope-To: 8857 Cc: Glenn Morris , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.8 (--) martin rudalics writes: >> Is this supposed to also fix the problem for batch mode? Because I still >> see this error with revno. 104589: > > It was supposed to fix that, yes. > >> --> emacs --batch foo bar baz >> Unknown terminal type > > Can you check whether `display-buffer' tries to pop up a new buffer? I > don't have the slightest experience running Emacs in batch mode. I don't know if this is what you're looking for, but when I run this: --> emacs --batch -Q --eval "(debug-on-entry 'display-buffer-pop-up-window)" foo bar baz I get this: Debugger entered--entering a function: display-buffer-pop-up-window(# ((largest) (lru)) ((pop-up-frame) (reuse-window other other visible) (reuse-window nil same visible) (pop-up-window (largest) (lru)) (reuse-window other other nil) (reuse-window-even-sizes . t) (reuse-window nil same visible) (pop-up-window (largest) (lru)) (pop-up-frame) (pop-up-frame-alist (height . 24) (width . 80) (unsplittable . t)) (reuse-window nil other visible) (reuse-window-even-sizes . t))) * display-buffer(# other-window nil) pop-to-buffer(# other-window nil) switch-to-buffer-other-window(#) find-file-other-window("/home/void/bar") command-line-1(("--eval" "(debug-on-entry 'display-buffer-pop-up-window)" "foo" "bar" "baz")) command-line() normal-top-level() Cheers, David From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 15:16:17 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 19:16:18 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWvZZ-0003Vm-CT for submit@debbugs.gnu.org; Wed, 15 Jun 2011 15:16:17 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWvZX-0003Vb-BH for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 15:16:15 -0400 Received: from localhost ([127.0.0.1]:60248) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWvZQ-0003Ez-9w; Wed, 15 Jun 2011 15:16:08 -0400 From: Glenn Morris To: David Engster Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF8EFB3.1060304@gmx.at> <36ips7otku.fsf@fencepost.gnu.org> <87k4cnklnw.fsf@engster.org> X-Spook: Ceridian JUWTF chameleon man csystems Roswell sweep X-Ran: '~*XarX_kmv7r|]T)irLr~Mb`V|!SfBuo[#9GCw/V1QD/7Gzlz^eLy/}l:ADh"hGREV74H X-Hue: yellow X-Debbugs-No-Ack: yes X-Attribution: GM Date: Wed, 15 Jun 2011 15:16:07 -0400 In-Reply-To: <87k4cnklnw.fsf@engster.org> (David Engster's message of "Wed, 15 Jun 2011 20:13:39 +0200") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: 8857 Cc: martin rudalics , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.3 (------) David Engster wrote: > It also fails with "-Q" (and "--batch" implies "-q", at least). Oh, I forgot that batch implies -q. Yes, it's still trying to pop-up frames for me too. ./src/emacs -Q -batch BUGS README INSTALL README:reuse-window README:pop-up-window INSTALL:reuse-window INSTALL:pop-up-window INSTALL:pop-up-frame Unknown terminal type From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 15:33:13 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 19:33:13 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWvpx-0003sz-07 for submit@debbugs.gnu.org; Wed, 15 Jun 2011 15:33:13 -0400 Received: from mailout-de.gmx.net ([213.165.64.23]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1QWvpt-0003sl-0s for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 15:33:10 -0400 Received: (qmail invoked by alias); 15 Jun 2011 19:33:02 -0000 Received: from 62-47-61-83.adsl.highway.telekom.at (EHLO [62.47.61.83]) [62.47.61.83] by mail.gmx.net (mp005) with SMTP; 15 Jun 2011 21:33:02 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX1/c7lMdJUDcBp8VhCFthKzPVYNvf6fvtA5cAV24tS X1d3rz5CMUmaoW Message-ID: <4DF908EB.8000204@gmx.at> Date: Wed, 15 Jun 2011 21:32:59 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) MIME-Version: 1.0 To: David Engster Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF8EFB3.1060304@gmx.at> <87fwnbkkvd.fsf@engster.org> In-Reply-To: <87fwnbkkvd.fsf@engster.org> Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Spam-Score: -2.5 (--) X-Debbugs-Envelope-To: 8857 Cc: Glenn Morris , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.5 (--) > I don't know if this is what you're looking for, but when I run this: More or less so, thanks. Putting the debug-on-entry on `display-buffer-pop-up-frame' would have been more indicative. > --> emacs --batch -Q --eval "(debug-on-entry 'display-buffer-pop-up-window)" foo bar baz > > I get this: > > Debugger entered--entering a function: > display-buffer-pop-up-window(# ((largest) (lru)) ((pop-up-frame) (reuse-window ... ^^^^^^^^^^^^^^ `display-buffer-pop-up-window' likely fails here to produce a window and next `display-buffer' tries to pop up a new frame. > * display-buffer(# other-window nil) > pop-to-buffer(# other-window nil) > switch-to-buffer-other-window(#) > find-file-other-window("/home/void/bar") > command-line-1(("--eval" "(debug-on-entry 'display-buffer-pop-up-window)" "foo" "bar" "baz")) > command-line() > normal-top-level() The problem is that `switch-to-buffer-other-window' has to use "another" window. If it can't pop up a window on the selected frame it tries to pop up a new frame :-( As Glenn remarked - you can get the same problem by setting `pop-up-frames' to t. What shall I do? martin From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 15:40:40 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 19:40:40 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWvxA-00042z-Ap for submit@debbugs.gnu.org; Wed, 15 Jun 2011 15:40:40 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWvx8-00042n-E5 for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 15:40:39 -0400 Received: from localhost ([127.0.0.1]:49885) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWvx2-00053x-HM; Wed, 15 Jun 2011 15:40:32 -0400 From: Glenn Morris To: Stefan Monnier Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> X-Spook: Glock Albright Operation Iraqi Freedom Ansar al-Islam X-Ran: xR?Lw9xQiRkyKy6uSt?Q#E5RO'4@gV`-u&DLADgU{T]n0Dr$S~_@ (Stefan Monnier's message of "Wed, 15 Jun 2011 10:36:56 -0400") Message-ID: <3y39jaq3ww.fsf@fencepost.gnu.org> User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: 8857 Cc: martin rudalics , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.3 (------) Stefan Monnier wrote: > "batch mode" and "server mode" are *very* closely related. So I'd stay > away from any attempt to special case "batch mode". FWIW, `noninteractive' is nil in "server mode" (ie --daemon) but t in "batch mode", so the two cases are easily distinguished. Since emacs.c has: if (!noninteractive) init_display (); /* Determine terminal type. Calls init_sys_modes. */ I've gone back to thinking that display-buffer can do nothing useful in batch mode. From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 15:43:36 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 19:43:36 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWvzz-00046x-Nl for submit@debbugs.gnu.org; Wed, 15 Jun 2011 15:43:36 -0400 Received: from v3-1008.vxen.de ([79.140.41.8]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWvzw-00046j-LY for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 15:43:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=randomsample.de; s=a; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To:Subject:Cc:To:From; bh=CN7UGocIQTjIH2qmb0H6Y567Na6GrkWlDzpdUqeJOkU=; b=oSuU8U9Cn4rA/A4jOkkncajRgC5Ua2dugdiCru9pBXw+1W9hHfhvZ7jR1XAVxbO/VNsoSW4Q8CTx+5yah3TP67Gfbgud3qTGoUANwffz27QZ1KEYHp5BlsjxVBhL5HTj; Received: from dslc-082-083-039-127.pools.arcor-ip.net ([82.83.39.127] helo=spaten) by v3-1008.vxen.de with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1QWvzq-0007N4-Rv; Wed, 15 Jun 2011 21:43:26 +0200 From: David Engster To: martin rudalics Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error In-Reply-To: <4DF908EB.8000204@gmx.at> (martin rudalics's message of "Wed, 15 Jun 2011 21:32:59 +0200") References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF8EFB3.1060304@gmx.at> <87fwnbkkvd.fsf@engster.org> <4DF908EB.8000204@gmx.at> User-Agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (gnu/linux) Date: Wed, 15 Jun 2011 21:42:28 +0200 Message-ID: <878vt2lw4b.fsf@engster.org> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.8 (--) X-Debbugs-Envelope-To: 8857 Cc: Glenn Morris , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.8 (--) martin rudalics writes: > The problem is that `switch-to-buffer-other-window' has to use "another" > window. If it can't pop up a window on the selected frame it tries to > pop up a new frame :-( As Glenn remarked - you can get the same problem > by setting `pop-up-frames' to t. What shall I do? I'm a bit confused. Yes, Emacs23 shows the same error with pop-up-frames to 't'. However, if I explicitly set it to 'nil' for Emacs24, I still get the same error: --> emacs --batch -Q --eval "(setq pop-up-frames nil)" foo bar baz Unknown terminal type If the issue is really just the changed default for `pop-up-frames', I'd say the default should be again changed to 'graphic-only instead of 'unset. -David From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 17:02:59 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 21:02:59 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWxEo-0005vz-LH for submit@debbugs.gnu.org; Wed, 15 Jun 2011 17:02:59 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.181] helo=ironport2-out.pppoe.ca) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWxEm-0005vo-G2 for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 17:02:57 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av0EADYd+U1MCozA/2dsb2JhbABSpll4iHO/OYYmBJ0/hBs X-IronPort-AV: E=Sophos;i="4.65,371,1304308800"; d="scan'208";a="116407318" Received: from 76-10-140-192.dsl.teksavvy.com (HELO pastel.home) ([76.10.140.192]) by ironport2-out.pppoe.ca with ESMTP/TLS/ADH-AES256-SHA; 15 Jun 2011 17:02:50 -0400 Received: by pastel.home (Postfix, from userid 20848) id 6683E59010; Wed, 15 Jun 2011 17:02:50 -0400 (EDT) From: Stefan Monnier To: Glenn Morris Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error Message-ID: References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <3y39jaq3ww.fsf@fencepost.gnu.org> Date: Wed, 15 Jun 2011 17:02:50 -0400 In-Reply-To: <3y39jaq3ww.fsf@fencepost.gnu.org> (Glenn Morris's message of "Wed, 15 Jun 2011 15:40:31 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.1 (--) X-Debbugs-Envelope-To: 8857 Cc: martin rudalics , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.1 (--) >> "batch mode" and "server mode" are *very* closely related. So I'd stay >> away from any attempt to special case "batch mode". > FWIW, `noninteractive' is nil in "server mode" (ie --daemon) but t in > "batch mode", so the two cases are easily distinguished. > Since emacs.c has: > if (!noninteractive) > init_display (); /* Determine terminal type. Calls init_sys_modes. */ > I've gone back to thinking that display-buffer can do nothing useful in > batch mode. It might fix it for batch mode, but you may get the same problem in "server mode before opening any display or tty". That's what I mean by the two being closely related. I.e. we need to make it work on the dummy initial terminal. Stefan From unknown Thu Sep 11 20:36:39 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: Did not alter fixed versions and reopened. Date: Wed, 15 Jun 2011 22:09:02 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # Did not alter fixed versions and reopened. thanks # This fakemail brought to you by your local debbugs # administrator From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 15 18:13:52 2011 Received: (at 8857) by debbugs.gnu.org; 15 Jun 2011 22:13:52 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWyLQ-0007VW-C1 for submit@debbugs.gnu.org; Wed, 15 Jun 2011 18:13:52 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QWyLO-0007VK-OM for 8857@debbugs.gnu.org; Wed, 15 Jun 2011 18:13:51 -0400 Received: from localhost ([127.0.0.1]:47156) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QWyLJ-0006MI-9I; Wed, 15 Jun 2011 18:13:45 -0400 From: Glenn Morris To: Stefan Monnier Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <3y39jaq3ww.fsf@fencepost.gnu.org> X-Spook: terrorist Commecen analyzer White House NSA quiche X-Ran: Hu5;!we'/z|V[AO@#rppu(*R*D)9^)B%^\(A9XV[YfzFYgxAd)Lhp(M(dhm:^Bl1`>aqIz X-Hue: yellow X-Debbugs-No-Ack: yes X-Attribution: GM Date: Wed, 15 Jun 2011 18:13:44 -0400 Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: 8857 Cc: martin rudalics , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.3 (------) Stefan Monnier wrote: > It might fix it for batch mode, but you may get the same problem in > "server mode before opening any display or tty". That's what I mean by > the two being closely related. > > I.e. we need to make it work on the dummy initial terminal. I'm not so sure, because server mode at least _has_ a dummy terminal. Can you give an example of server mode running into the same problem as being discussed for batch mode? From debbugs-submit-bounces@debbugs.gnu.org Thu Jun 16 05:23:56 2011 Received: (at 8857) by debbugs.gnu.org; 16 Jun 2011 09:23:56 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QX8nr-0005z2-E2 for submit@debbugs.gnu.org; Thu, 16 Jun 2011 05:23:55 -0400 Received: from mailout-de.gmx.net ([213.165.64.22]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1QX8np-0005yr-Ah for 8857@debbugs.gnu.org; Thu, 16 Jun 2011 05:23:54 -0400 Received: (qmail invoked by alias); 16 Jun 2011 09:23:46 -0000 Received: from 62-47-53-112.adsl.highway.telekom.at (EHLO [62.47.53.112]) [62.47.53.112] by mail.gmx.net (mp042) with SMTP; 16 Jun 2011 11:23:46 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX19GUDELaRlGqP457bV1oYjZnwQSqVEs6cdurF1mkp 3yYQgzA/Vuyzv6 Message-ID: <4DF9CBA1.1090307@gmx.at> Date: Thu, 16 Jun 2011 11:23:45 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) MIME-Version: 1.0 To: David Engster Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> In-Reply-To: <87oc1zkp0n.fsf@engster.org> Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Spam-Score: -2.5 (--) X-Debbugs-Envelope-To: 8857 Cc: Glenn Morris , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.5 (--) > Is this supposed to also fix the problem for batch mode? Because I still > see this error with revno. 104589: > > --> emacs --batch foo bar baz > Unknown terminal type > > Actually, this currently breaks the CEDET build, because it uses a hack > to provide arguments for functions called with the "-f" switch... My earlier fix wasn't rigid enough. Please try again. Thanks, martin From debbugs-submit-bounces@debbugs.gnu.org Thu Jun 16 06:04:31 2011 Received: (at 8857) by debbugs.gnu.org; 16 Jun 2011 10:04:31 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QX9R9-0006sA-4p for submit@debbugs.gnu.org; Thu, 16 Jun 2011 06:04:31 -0400 Received: from v3-1008.vxen.de ([79.140.41.8]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QX9R5-0006rx-W0 for 8857@debbugs.gnu.org; Thu, 16 Jun 2011 06:04:29 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=randomsample.de; s=a; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To:Subject:Cc:To:From; bh=CGZQuBVUGWX2vU6VcBOkeVzhPQCN5F1djw3Mh39O4iY=; b=j29AkuR5IjI671qdtHjr2aw4A6db8lsNg1V5eYcyxbiaiOXltrkLAyVtoPPP2SF1cPOVVmm/UdVJJv+5v/3EYNBQjjzMjGhAg/GlyazNG5LKM+L5e6V99TXNZyReC8qv; Received: from ibookg4-c2.pc.gwdg.de ([134.76.4.219]) by v3-1008.vxen.de with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1QX9Qy-0004pC-UA; Thu, 16 Jun 2011 12:04:21 +0200 From: David Engster To: martin rudalics Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error In-Reply-To: <4DF9CBA1.1090307@gmx.at> (martin rudalics's message of "Thu, 16 Jun 2011 11:23:45 +0200") References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF9CBA1.1090307@gmx.at> User-Agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (darwin) Date: Thu, 16 Jun 2011 12:04:15 +0200 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -3.3 (---) X-Debbugs-Envelope-To: 8857 Cc: Glenn Morris , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.3 (---) martin rudalics writes: >> Is this supposed to also fix the problem for batch mode? Because I still >> see this error with revno. 104589: >> >> --> emacs --batch foo bar baz >> Unknown terminal type >> >> Actually, this currently breaks the CEDET build, because it uses a hack >> to provide arguments for functions called with the "-f" switch... > > My earlier fix wasn't rigid enough. Please try again. Works for me. Thanks! BTW, but I think related to this, I don't really understand the new default for pop-up-frames. The doc-string says: "If this is the symbol unset, the option was not set and is ignored." Sorry, but I think this is a bit of a cop-out. You can't really ignore a boolean option - you either pop up a new frame or you don't; it all just depends on how you handle "unset", and this introduces ambiguity in the code. A quick grep shows me that pop-up-frames is either tested with (if (memq pop-up-frames '(nil unset)) ... which means 'unset is actually handled as "not set", or it is simply tested with (if pop-up-frames ... which means 'unset is handled as "set". I would vote for setting the default to 'graphic-only. (Maybe this is the wrong place to discuss this - please let me know if I should file another bug-report or bring this to emacs-devel). -David From debbugs-submit-bounces@debbugs.gnu.org Thu Jun 16 09:28:12 2011 Received: (at 8857) by debbugs.gnu.org; 16 Jun 2011 13:28:12 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QXCcG-0000Sd-4y for submit@debbugs.gnu.org; Thu, 16 Jun 2011 09:28:12 -0400 Received: from mailout-de.gmx.net ([213.165.64.22]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1QXCcC-0000SQ-Om for 8857@debbugs.gnu.org; Thu, 16 Jun 2011 09:28:10 -0400 Received: (qmail invoked by alias); 16 Jun 2011 13:01:21 -0000 Received: from 62-47-41-3.adsl.highway.telekom.at (EHLO [62.47.41.3]) [62.47.41.3] by mail.gmx.net (mp060) with SMTP; 16 Jun 2011 15:01:21 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX19g0MkItGtgNECZNidL/KkuXeqAE+2/dP4JF2FeSO cJQEBuhESH2Jvg Message-ID: <4DF9FE9D.3080609@gmx.at> Date: Thu, 16 Jun 2011 15:01:17 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) MIME-Version: 1.0 To: David Engster Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF9CBA1.1090307@gmx.at> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Spam-Score: -2.5 (--) X-Debbugs-Envelope-To: 8857 Cc: Glenn Morris , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.5 (--) > BTW, but I think related to this, I don't really understand the new > default for pop-up-frames. The doc-string says: > > "If this is the symbol unset, the option was not set and is > ignored." 'unset stands for "nobody bothered to set or bind this". > Sorry, but I think this is a bit of a cop-out. You can't really ignore a > boolean option - you either pop up a new frame or you don't; it all just > depends on how you handle "unset", and this introduces ambiguity in the > code. A quick grep shows me that pop-up-frames is either tested with > > (if (memq pop-up-frames '(nil unset)) > ... > > which means 'unset is actually handled as "not set", Because it's the same for `display-buffer'. > or it is simply > tested with > > (if pop-up-frames > ... I can't find this anywhere :-( > which means 'unset is handled as "set". But an application should be allowed to test whether the user or the calling application has set this option in some way or the other before possibly (re-)binding it. If the value is still 'unset, no one bothered about it. If it is nil, someone up there explicitly doesn't want to pop up buffers. If it's graphic-only, someone up there wants to pop them up on graphic systems only. Any other value means that someone wants to pop up frames anywhere. Not that applications care that much ... > I would vote for setting the default to 'graphic-only. IIRC the default was nil. 'graphic-only was IMHO a not very well-conceived idea because it didn't inhibit applications to rebind this to t. I've never seen a `pop-up-frames' rebinding function care about this issue. Personally, I'd prefer such an option to affect the behavior of the frame creation functions rather than that of display-buffer. But I don't recall the reason that lead to the introduction of graphic-only. In any case, we could conceive an additional variable (not necessarily an option), say `display-buffer-pop-up-frame-graphic-only', which, if non-nil, effectively inhibits popping up a new frame on non-graphic systems, overriding any value calculated from buffer display specifiers and `pop-up-frames'. > (Maybe this is the wrong place to discuss this - please let me know if I > should file another bug-report or bring this to emacs-devel). Please do what you find more convenient ;-) BTW, Drew started a related discussion in another thread. I asked him to join us. martin From debbugs-submit-bounces@debbugs.gnu.org Thu Jun 16 09:57:39 2011 Received: (at 8857) by debbugs.gnu.org; 16 Jun 2011 13:57:40 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QXD4l-000202-3L for submit@debbugs.gnu.org; Thu, 16 Jun 2011 09:57:39 -0400 Received: from v3-1008.vxen.de ([79.140.41.8]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QXD4i-0001zo-C7 for 8857@debbugs.gnu.org; Thu, 16 Jun 2011 09:57:37 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=randomsample.de; s=a; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To:Subject:Cc:To:From; bh=SFmrP6DGrHyTRpTiHdqu92l38OUVKaxtU5c9/le4JPw=; b=aKH1E8UcKf3fMZClwVfTstBtC4ugBjIwv8nljdncBjiFYYzqdb7hoaq7s4dfP2YGOdlDdkSxh5Q+h3jF9C8QWu8pXL2z1yuExSFqJRMii2DJEfz9qv6OqCemMH04t8jo; Received: from ibookg4-c2.pc.gwdg.de ([134.76.4.219]) by v3-1008.vxen.de with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1QXD4c-00087e-C0; Thu, 16 Jun 2011 15:57:30 +0200 From: David Engster To: martin rudalics Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error In-Reply-To: <4DF9FE9D.3080609@gmx.at> (martin rudalics's message of "Thu, 16 Jun 2011 15:01:17 +0200") References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF9CBA1.1090307@gmx.at> <4DF9FE9D.3080609@gmx.at> User-Agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (darwin) Date: Thu, 16 Jun 2011 15:57:24 +0200 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -3.2 (---) X-Debbugs-Envelope-To: 8857 Cc: Glenn Morris , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.2 (---) martin rudalics writes: >> BTW, but I think related to this, I don't really understand the new >> default for pop-up-frames. The doc-string says: >> >> "If this is the symbol unset, the option was not set and is >> ignored." > > 'unset stands for "nobody bothered to set or bind this". > >> Sorry, but I think this is a bit of a cop-out. You can't really ignore a >> boolean option - you either pop up a new frame or you don't; it all just >> depends on how you handle "unset", and this introduces ambiguity in the >> code. A quick grep shows me that pop-up-frames is either tested with >> >> (if (memq pop-up-frames '(nil unset)) >> ... >> >> which means 'unset is actually handled as "not set", > > Because it's the same for `display-buffer'. I see. > >> or it is simply >> tested with >> >> (if pop-up-frames >> ... > > I can't find this anywhere :-( Sorry, I should have been more explicit: There are places in the Emacs sources which only test pop-up-frames for being non-nil, usually with 'and'/'or': calendar/diary-lib.el: (let* ((pop-up-frames (or pop-up-frames (window-dedicated-p (selected-window)))) mail/rmail.el: (and pop-up-frames (one-window-p)) progmodes/inf-lisp.el: (let ((pop-up-frames ;; Be willing to use another frame ;; that already has the window in it. (or pop-up-frames (get-buffer-window inferior-lisp-buffer t)))) vc/pcvs-util.el: (let ((pop-up-windows (or pop-up-windows pop-up-frames)) ... just to mention a few. >> which means 'unset is handled as "set". > > But an application should be allowed to test whether the user or the > calling application has set this option in some way or the other before > possibly (re-)binding it. If the value is still 'unset, no one bothered > about it. If it is nil, someone up there explicitly doesn't want to pop > up buffers. If it's graphic-only, someone up there wants to pop them up > on graphic systems only. Any other value means that someone wants to > pop up frames anywhere. Not that applications care that much ... OK, I think I understand the motivation behind 'unset now. However, this effectively means that there really is no default value for pop-up-frames, and every application can decide how they will deal with that. The snippets above will see it as non-nil and will now create frames. >> I would vote for setting the default to 'graphic-only. > > IIRC the default was nil. 'graphic-only was IMHO a not very > well-conceived idea because it didn't inhibit applications to rebind > this to t. I've never seen a `pop-up-frames' rebinding function care > about this issue. Right, the current code doesn't care about 'graphic-only, but neither does the old code care about 'unset. This can be changed, of course... :-) >> (Maybe this is the wrong place to discuss this - please let me know if I >> should file another bug-report or bring this to emacs-devel). > > Please do what you find more convenient ;-) > > BTW, Drew started a related discussion in another thread. I asked him > to join us. I actually don't feel that strongly about it. It just found it confusing, but I think I understand it better now. I have set this option to nil anyway. :-) Thanks for explaining, David From debbugs-submit-bounces@debbugs.gnu.org Thu Jun 16 10:17:12 2011 Received: (at 8857) by debbugs.gnu.org; 16 Jun 2011 14:17:13 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QXDNg-0002S1-C3 for submit@debbugs.gnu.org; Thu, 16 Jun 2011 10:17:12 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.181] helo=ironport2-out.pppoe.ca) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QXDNc-0002Rk-Vy; Thu, 16 Jun 2011 10:17:10 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av0EALcP+k1MCozA/2dsb2JhbABSpl94iHPAeoYnBJ1OhB0 X-IronPort-AV: E=Sophos;i="4.65,375,1304308800"; d="scan'208";a="116445513" Received: from 76-10-140-192.dsl.teksavvy.com (HELO pastel.home) ([76.10.140.192]) by ironport2-out.pppoe.ca with ESMTP/TLS/ADH-AES256-SHA; 16 Jun 2011 10:17:02 -0400 Received: by pastel.home (Postfix, from userid 20848) id 77B5859010; Thu, 16 Jun 2011 10:17:02 -0400 (EDT) From: Stefan Monnier To: martin rudalics Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error Message-ID: References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF9CBA1.1090307@gmx.at> <4DF9FE9D.3080609@gmx.at> Date: Thu, 16 Jun 2011 10:17:02 -0400 In-Reply-To: <4DF9FE9D.3080609@gmx.at> (martin rudalics's message of "Thu, 16 Jun 2011 15:01:17 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.1 (--) X-Debbugs-Envelope-To: 8857 Cc: 8857@debbugs.gnu.org, David Engster X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.1 (--) > IIRC the default was nil. 'graphic-only was IMHO a not very > well-conceived idea because it didn't inhibit applications to rebind > this to t. I've never seen a `pop-up-frames' rebinding function care > about this issue. graphics-only was a quick fix for people who want to set pop-up-frames in their .emacs but get annoyed when they tty-emacsclient end up popping up frames as well. > In any case, we could conceive an additional variable (not necessarily > an option), say `display-buffer-pop-up-frame-graphic-only', which, if > non-nil, effectively inhibits popping up a new frame on non-graphic > systems, overriding any value calculated from buffer display specifiers > and `pop-up-frames'. More generally we want to specify different display-buffer behaviors for tty (where frames are fully-overlapping) and graphic terminals (where several frames may be visible at the same time). Stefan From debbugs-submit-bounces@debbugs.gnu.org Thu Jun 16 11:08:32 2011 Received: (at 8857) by debbugs.gnu.org; 16 Jun 2011 15:08:32 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QXEBM-0005vL-8M for submit@debbugs.gnu.org; Thu, 16 Jun 2011 11:08:32 -0400 Received: from mailout-de.gmx.net ([213.165.64.23]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1QXEBJ-0005v7-Re for 8857@debbugs.gnu.org; Thu, 16 Jun 2011 11:08:31 -0400 Received: (qmail invoked by alias); 16 Jun 2011 15:08:23 -0000 Received: from 62-47-62-1.adsl.highway.telekom.at (EHLO [62.47.62.1]) [62.47.62.1] by mail.gmx.net (mp071) with SMTP; 16 Jun 2011 17:08:23 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX18A1P5ssuAA1MrUaWngZf2ZetoOE4k+7HcojaWSUM NMDT1pYHGEKJER Message-ID: <4DFA1C65.2070306@gmx.at> Date: Thu, 16 Jun 2011 17:08:21 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) MIME-Version: 1.0 To: David Engster Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF9CBA1.1090307@gmx.at> <4DF9FE9D.3080609@gmx.at> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Spam-Score: -1.7 (-) X-Debbugs-Envelope-To: 8857 Cc: Glenn Morris , 8857@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.7 (-) > calendar/diary-lib.el: > > (let* ((pop-up-frames (or pop-up-frames > (window-dedicated-p (selected-window)))) > > mail/rmail.el: > > (and pop-up-frames (one-window-p)) > > progmodes/inf-lisp.el: > > (let ((pop-up-frames > ;; Be willing to use another frame > ;; that already has the window in it. > (or pop-up-frames > (get-buffer-window inferior-lisp-buffer t)))) > > vc/pcvs-util.el: > > (let ((pop-up-windows (or pop-up-windows pop-up-frames)) > > ... just to mention a few. I replaced most of these in my window-pub branch which, however, doesn't care about 'unset value yet. Obviously, all of these don't DTRT in Emacs 23 when a user has set `pop-up-frames' to 'graphic-only and is on a non-graphic system. > OK, I think I understand the motivation behind 'unset now. 'unset was a quick fix to make old code work with the new `display-buffer'. There might be some yet unknown quirks in it. Maybe I even don't need it. > However, this > effectively means that there really is no default value for > pop-up-frames, ... well it's 'unset ... > and every application can decide how they will deal with > that. The snippets above will see it as non-nil and will now create > frames. Yes. Just as they wrongly handled 'graphic-only in Emacs 23. > Right, the current code doesn't care about 'graphic-only, but neither > does the old code care about 'unset. This can be changed, of course... :-) This must be changed, of course :-) > I actually don't feel that strongly about it. It just found it > confusing, but I think I understand it better now. I have set this > option to nil anyway. :-) Me too. That's why I'm not very familiar with the ensuing problems. martin From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 17 02:49:53 2011 Received: (at 8857-done) by debbugs.gnu.org; 17 Jun 2011 06:49:53 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QXSsK-00087k-Jx for submit@debbugs.gnu.org; Fri, 17 Jun 2011 02:49:52 -0400 Received: from v3-1008.vxen.de ([79.140.41.8]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QXSsH-00087V-D9 for 8857-done@debbugs.gnu.org; Fri, 17 Jun 2011 02:49:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=randomsample.de; s=a; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To:Subject:Cc:To:From; bh=unsuRu3ItnDtlXgoHBuTMWfEEVAtfnQ2sSLSK2jP1w8=; b=QzOP4rIueWbhDRdPrSYViyAbsljuCQd8g+Xia/FGTVqHvQGe62sNcezHn79qbbllK+O1c/NIl8qijSwDoaSzxmim7DwwgCt8h0W1gMbZ9qunOHu9U+yc1DoEojf9I2q9; Received: from ibookg4-c2.pc.gwdg.de ([134.76.4.219]) by v3-1008.vxen.de with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1QXSsA-0006ZI-0q; Fri, 17 Jun 2011 08:49:42 +0200 From: David Engster To: martin rudalics Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error In-Reply-To: <4DFA1C65.2070306@gmx.at> (martin rudalics's message of "Thu, 16 Jun 2011 17:08:21 +0200") References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF9CBA1.1090307@gmx.at> <4DF9FE9D.3080609@gmx.at> <4DFA1C65.2070306@gmx.at> User-Agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (darwin) Mail-Copies-To: never Date: Fri, 17 Jun 2011 08:49:36 +0200 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -3.2 (---) X-Debbugs-Envelope-To: 8857-done Cc: 8857-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.2 (---) martin rudalics writes: >> However, this >> effectively means that there really is no default value for >> pop-up-frames, > > ... well it's 'unset ... Yes. But I think you understand my problem: 'unset doesn't say whether you should pop up a new frame by default or not. It's pretty much what Drew says in #8865, and I tend to agree with him on this issue. I think this special handling of 'unset is cumbersome, and it should simply be a boolean variable with a default of nil or t. Anyway, I don't want to bother you with two threads on the same issue, and the original problem has been solved, so I'm closing this bug and will maybe follow-up on #8865, but I think pretty much everything has been said regarding this issue. -David From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 17 04:50:17 2011 Received: (at 8857-done) by debbugs.gnu.org; 17 Jun 2011 08:50:17 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QXUkr-0008PO-A0 for submit@debbugs.gnu.org; Fri, 17 Jun 2011 04:50:17 -0400 Received: from mailout-de.gmx.net ([213.165.64.23]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1QXUkn-0008PA-11 for 8857-done@debbugs.gnu.org; Fri, 17 Jun 2011 04:50:14 -0400 Received: (qmail invoked by alias); 17 Jun 2011 08:50:06 -0000 Received: from 62-47-53-146.adsl.highway.telekom.at (EHLO [62.47.53.146]) [62.47.53.146] by mail.gmx.net (mp005) with SMTP; 17 Jun 2011 10:50:06 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX19pbF8FtbRpjNhTclWvM+CAPGio6kL/mInN1S27j/ 8Q2bZdi2Ativnt Message-ID: <4DFB153C.4070005@gmx.at> Date: Fri, 17 Jun 2011 10:50:04 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) MIME-Version: 1.0 To: David Engster Subject: Re: bug#8857: display-buffer attempt to pop-up frame in batch mode causes "Unknown terminal type" error References: <4DF726E0.6020205@gmx.at> <4DF79707.7000707@gmx.at> <4DF7A0D0.2030707@gmx.at> <4DF7B1D2.3010304@gmx.at> <9ypqmfy2lo.fsf@fencepost.gnu.org> <4DF866F7.3070006@gmx.at> <87oc1zkp0n.fsf@engster.org> <4DF9CBA1.1090307@gmx.at> <4DF9FE9D.3080609@gmx.at> <4DFA1C65.2070306@gmx.at> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Spam-Score: -2.5 (--) X-Debbugs-Envelope-To: 8857-done Cc: 8857-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.5 (--) > Yes. But I think you understand my problem: 'unset doesn't say whether > you should pop up a new frame by default or not. It's pretty much what > Drew says in #8865, and I tend to agree with him on this issue. I think > this special handling of 'unset is cumbersome, and it should simply be a > boolean variable with a default of nil or t. Done. I have retained the 'unset initialization for `pop-up-windows' though and introduced a new one for `even-window-heights' since these variables were non-nil by default. Please have a look. martin From unknown Thu Sep 11 20:36:39 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Fri, 29 Jul 2011 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator