unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#20549: 24.5; tcl.el: sending region to tcl process produces error
@ 2015-05-11 17:52 a.c.kalker
  2015-05-11 18:10 ` bug#20549: Sample TCL command to send Alain Kalker
  2015-05-12  6:39 ` bug#20549: 24.5; tcl.el: sending region to tcl process produces error Glenn Morris
  0 siblings, 2 replies; 6+ messages in thread
From: a.c.kalker @ 2015-05-11 17:52 UTC (permalink / raw)
  To: 20549


Steps to reproduce:
- Visit a Tcl boffer
- Start a new Tcl process using C-c C-t
- Select a region containing one or more Tcl commands
- Try and send it to the Tcl process using C-c C-x

Actual results:
- Emacs reports an error: "error in process filter: Text is read-only"
- No Tcl commands are sent to the Tcl process
- Further interaction with the Tcl process buffer becomes erratic

Expected results:
- The region should be sent to the Tcl process, and any commands should
be executed.
- The Tcl process buffer should interact normally, accepting new
manually entered commands and displaying their results.

From some experimenting and some helpful discussion on IRC, I found that
a very likely cause of the problem is the way in which Tcl mode tries to
erase the prompt in a process buffer.  Apparently it doesn't handle
read-only prompts correctly.



In GNU Emacs 24.5.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.16.2)
 of 2015-04-20 on bitzer.hoetzel.info
Windowing system distributor `The X.Org Foundation', version 11.0.11701000
Configured using:
 `configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib
 --localstatedir=/var --with-x-toolkit=gtk3 --with-xft
 'CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong
 --param=ssp-buffer-size=4' CPPFLAGS=-D_FORTIFY_SOURCE=2
 LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro'

Important settings:
  value of $LANG: en_US.utf8
  locale-coding-system: utf-8-unix

Major mode: Tcl

Minor modes in effect:
  delete-selection-mode: t
  yas-global-mode: t
  yas-minor-mode: t
  show-paren-mode: t
  icomplete-mode: t
  google-this-mode: t
  global-whitespace-mode: t
  global-flycheck-mode: t
  flycheck-mode: t
  global-company-mode: t
  company-mode: t
  cua-mode: t
  server-mode: t
  auto-compile-on-load-mode: t
  auto-compile-on-save-mode: t
  tooltip-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  column-number-mode: t
  line-number-mode: t
  transient-mark-mode: (only . t)

Recent messages:
[yas] Loading for `emacs-lisp-mode', just-in-time: (lambda nil (yas--load-directory-1 (quote /home/miki/.emacs.d/elpa/yasnippet-20150415.244/snippets/emacs-lisp-mode) (quote emacs-lisp-mode)))!
[yas] Loading compiled snippets from /home/miki/.emacs.d/elpa/yasnippet-20150415.244/snippets/emacs-lisp-mode
[yas] Loading for `prog-mode', just-in-time: (lambda nil (yas--load-directory-1 (quote /home/miki/.emacs.d/elpa/yasnippet-20150415.244/snippets/prog-mode) (quote prog-mode)))!
[yas] Loading compiled snippets from /home/miki/.emacs.d/elpa/yasnippet-20150415.244/snippets/prog-mode
Loading /home/miki/.emacs.d/elpa/yasnippet-20150415.244/snippets/prog-mode/.yas-setup...done
For information about GNU Emacs and the GNU system, type C-h C-a.
test.tcl has auto save data; consider M-x recover-this-file
C-c C-c is undefined [2 times]
Mark set
error in process filter: Text is read-only [2 times]

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message idna cl-macs rfc822 mml mml-sec
mm-decode mm-bodies mm-encode mailabbrev gmm-utils mailheader sendmail
tcl comint ansi-color mule-util hideshow eldoc elisp-slime-nav hl-sexp
.emacs saveplace imenu company-files company-oddmuse company-keywords
company-etags etags ring company-gtags company-dabbrev-code
company-dabbrev company-capf company-cmake company-xcode company-clang
company-semantic company-eclim company-template company-css company-nxml
company-bbdb company-irony irony-completion irony-snippet company-tern s
ucs-normalize dash-functional tern url-http tls url-auth mail-parse
rfc2231 rfc2047 rfc2045 ietf-drums url-gw json tsdh-dark-theme delsel
yasnippet cl gv paren icomplete google-this url url-proxy url-privacy
url-expand url-methods url-history url-cookie url-domsuf url-util
mailcap gnus gnus-ems nnheader mail-utils wid-edit whitespace
flycheck-irony irony-diagnostics irony flycheck find-func rx subr-x
company cua-base cus-start cus-load edmacro kmacro ix grapnel help-mode
easy-mmode dired+ image-dired format-spec image-file dired-x dired-aux
dired pkg-info-autoloads queue-autoloads info easymenu slime-autoloads
sly-autoloads package epg-config server ffap thingatpt url-parse
auth-source eieio eieio-core gnus-util mm-util mail-prsvr password-cache
url-vars jka-compr auto-compile byte-opt advice help-fns packed dash
bytecomp byte-compile cl-extra cl-loaddefs cl-lib cconv time-date
tooltip electric uniquify ediff-hook vc-hooks lisp-float-type mwheel
x-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list
newcomment lisp-mode prog-mode register page menu-bar rfn-eshadow timer
select scroll-bar mouse jit-lock font-lock syntax facemenu font-core
frame cham georgian utf-8-lang misc-lang vietnamese tibetan thai
tai-viet lao korean japanese hebrew greek romanian slovak czech european
ethiopic indian cyrillic chinese case-table epa-hook jka-cmpr-hook help
simple abbrev minibuffer nadvice loaddefs button faces cus-face macroexp
files text-properties overlay sha1 md5 base64 format env code-pages mule
custom widget hashtable-print-readable backquote make-network-process
dbusbind gfilenotify dynamic-setting system-font-setting
font-render-setting move-toolbar gtk x-toolkit x multi-tty emacs)

Memory information:
((conses 16 307146 13122)
 (symbols 48 30569 0)
 (miscs 40 107 134)
 (strings 32 49936 10483)
 (string-bytes 1 1483638)
 (vectors 16 44446)
 (vector-slots 8 797314 12468)
 (floats 8 417 615)
 (intervals 56 277 67)
 (buffers 960 15)
 (heap 1024 39504 4017))





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#20549: Sample TCL command to send
  2015-05-11 17:52 bug#20549: 24.5; tcl.el: sending region to tcl process produces error a.c.kalker
@ 2015-05-11 18:10 ` Alain Kalker
  2015-05-12  6:39 ` bug#20549: 24.5; tcl.el: sending region to tcl process produces error Glenn Morris
  1 sibling, 0 replies; 6+ messages in thread
From: Alain Kalker @ 2015-05-11 18:10 UTC (permalink / raw)
  To: 20549

For those who don't have Tcl for breakfast lunch and dinner, an example 
command to try is simply

puts 42

This should display the number 42.





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#20549: 24.5; tcl.el: sending region to tcl process produces error
  2015-05-11 17:52 bug#20549: 24.5; tcl.el: sending region to tcl process produces error a.c.kalker
  2015-05-11 18:10 ` bug#20549: Sample TCL command to send Alain Kalker
@ 2015-05-12  6:39 ` Glenn Morris
  2015-05-12 17:15   ` Alain Kalker
  1 sibling, 1 reply; 6+ messages in thread
From: Glenn Morris @ 2015-05-12  6:39 UTC (permalink / raw)
  To: a.c.kalker; +Cc: 20549

a.c.kalker@gmail.com wrote:

> - Visit a Tcl boffer
> - Start a new Tcl process using C-c C-t
> - Select a region containing one or more Tcl commands
> - Try and send it to the Tcl process using C-c C-x
>
> Actual results:
> - Emacs reports an error: "error in process filter: Text is read-only"

Thanks for the report, but I can't reproduce this.
Can you give a complete example starting from emacs -Q?





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#20549: 24.5; tcl.el: sending region to tcl process produces error
  2015-05-12  6:39 ` bug#20549: 24.5; tcl.el: sending region to tcl process produces error Glenn Morris
@ 2015-05-12 17:15   ` Alain Kalker
  2015-05-12 17:20     ` Alain Kalker
  2015-05-13  1:20     ` Glenn Morris
  0 siblings, 2 replies; 6+ messages in thread
From: Alain Kalker @ 2015-05-12 17:15 UTC (permalink / raw)
  To: Glenn Morris; +Cc: 20549



On 05/12/2015 08:39 AM, Glenn Morris wrote:
> a.c.kalker@gmail.com wrote:
>
>> - Visit a Tcl boffer
>> - Start a new Tcl process using C-c C-t
>> - Select a region containing one or more Tcl commands
>> - Try and send it to the Tcl process using C-c C-x
>>
>> Actual results:
>> - Emacs reports an error: "error in process filter: Text is read-only"
>
> Thanks for the report, but I can't reproduce this.
> Can you give a complete example starting from emacs -Q?

Ah, I'm sorry, i realize i did forget to mention a crucial piece of the 
puzzle (marked with + below), namely that I have customized a variable 
to have read-only prompts in comint buffers.
Here is the corrected list of steps:

- Start Emacs as `emacs -Q`
+ Configure prompts to be read-only using M-x set-variable RET 
comint-prompt-read-only RET t
- Visit a new Tcl file, example test.tcl
- Enter a Tcl command for testing, say `puts 42`
- Start Tcl process using C-c C-t
- Switch back to test.tcl buffer using C-x o
- Select all text using C-x h
- Try and send it to Tcl process using C-c C-x

This produces the error which I mentioned earlier.

Kind regards,

Alain





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#20549: 24.5; tcl.el: sending region to tcl process produces error
  2015-05-12 17:15   ` Alain Kalker
@ 2015-05-12 17:20     ` Alain Kalker
  2015-05-13  1:20     ` Glenn Morris
  1 sibling, 0 replies; 6+ messages in thread
From: Alain Kalker @ 2015-05-12 17:20 UTC (permalink / raw)
  To: Glenn Morris; +Cc: 20549

Ah, second and third steps need to be reversed. set-variable doesn't 
accept the variable name until after visiting a Tcl file.

On 05/12/2015 07:15 PM, Alain Kalker wrote:
> - Start Emacs as `emacs -Q`
> - Visit a new Tcl file, example test.tcl
> + Configure prompts to be read-only using M-x set-variable RET
> comint-prompt-read-only RET t
> - Enter a Tcl command for testing, say `puts 42`
> - Start Tcl process using C-c C-t
> - Switch back to test.tcl buffer using C-x o
> - Select all text using C-x h
> - Try and send it to Tcl process using C-c C-x
>
> This produces the error which I mentioned earlier.
>
> Kind regards,
>
> Alain





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#20549: 24.5; tcl.el: sending region to tcl process produces error
  2015-05-12 17:15   ` Alain Kalker
  2015-05-12 17:20     ` Alain Kalker
@ 2015-05-13  1:20     ` Glenn Morris
  1 sibling, 0 replies; 6+ messages in thread
From: Glenn Morris @ 2015-05-13  1:20 UTC (permalink / raw)
  To: 20549-done

Version: 25.1

Thanks; fixed.





^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-05-13  1:20 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-11 17:52 bug#20549: 24.5; tcl.el: sending region to tcl process produces error a.c.kalker
2015-05-11 18:10 ` bug#20549: Sample TCL command to send Alain Kalker
2015-05-12  6:39 ` bug#20549: 24.5; tcl.el: sending region to tcl process produces error Glenn Morris
2015-05-12 17:15   ` Alain Kalker
2015-05-12 17:20     ` Alain Kalker
2015-05-13  1:20     ` Glenn Morris

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).