all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Paul Pogonyshev <pogonyshev@gmail.com>
To: Michael Albinus <michael.albinus@gmx.de>
Cc: Lars Ingebrigtsen <larsi@gnus.org>, 57800@debbugs.gnu.org
Subject: bug#57800: TRAMP insert-file-contents now fails for regions
Date: Fri, 30 Sep 2022 10:49:27 +0200	[thread overview]
Message-ID: <CAG7BpapCHdakyC8NaYJ9F_Cio6ZBQjmK2b0mLnYJYz3ND24wqg@mail.gmail.com> (raw)
In-Reply-To: <87v8p6hyg4.fsf@gmx.de>


[-- Attachment #1.1: Type: text/plain, Size: 2169 bytes --]

Happened again. See attached `BACKTRACE' and `TRAMP-LOG' generated after
evalling `(setf tramp-verbose 10)'.

Note this suspicious entry in the log:
10:26:36.864700 tramp-get-remote-tmpdir (1) # File error: Directory
/ssh:USER@HOST#22222:/ssh:USER@HOST#22222:/tmp not accessible

Mentioned Git commit cannot be found, because I build Emacs with a few
minor local changes. I can assure you they have nothing to do with TRAMP.
The build is from 14th of September, so upstream commit number should be
around 997284d2a5 or so.

I will keep this Emacs instance around in case you have questions.

Paul

On Thu, 29 Sept 2022 at 19:39, Michael Albinus <michael.albinus@gmx.de>
wrote:

> Paul Pogonyshev <pogonyshev@gmail.com> writes:
>
> Hi Paul,
>
> > No, the bug is not reproducible all the time. I have switched to Emacs
> > 28 since then, as this breaks functionality important for me. Now
> > tried to run 29 again, but it doesn't happen anymore, neither with
> > `-Q' nor without. Also cannot find a backtrace for the same reason
> > now.
> >
> > From the reproducing early today I remember that restarting Emacs
> > doesn't help - or is at least random, since now a newly started Emacs
> > doesn't exhibit this problem. It feels like the problem is in some
> > cache and the cache appears to be persistent (cross-Emacs), if TRAMP
> > uses something like that at all.
> >
> > The files I have noticed this on have names like
> > "/ssh:USER@HOST#22222:/...", i.e. using SSH backend and a non-standard
> > port, if that matters.
>
> Thanks, this might make a difference when caching files. Ports are used
> for creating a file name index in the cache, but I'm not certain they
> are always taken into account, in all dark corners of Tramp. Will analyze.
>
> However, it would be great if you could reproduce the bug somehow in an
> Emacs instance started with
>
> --8<---------------cut here---------------start------------->8---
> emacs -Q --eval '(setq tramp-verbose 10)'
> --8<---------------cut here---------------end--------------->8---
>
> If the problem happens, pls show the recipe to provoke, and the Tramp
> debug buffer.
>
> > Paul
>
> Best regards, Michael.
>

[-- Attachment #1.2: Type: text/html, Size: 2852 bytes --]

[-- Attachment #2: BACKTRACE --]
[-- Type: application/octet-stream, Size: 5639 bytes --]

Debugger entered--Lisp error: (file-missing "/ssh:USER@HOST#22222:/PATH")
  signal(file-missing ("/ssh:USER@HOST#22222:/PATH"))
  tramp-error((tramp-file-name "ssh" "USER" nil "HOST" "22222" "/PATH" nil) file-missing "/ssh:USER@HOST#22222:/PATH")
  tramp-handle-insert-file-contents("/ssh:USER@HOST#22222:/PATH" nil 1 10 nil)
  apply(tramp-handle-insert-file-contents ("/ssh:USER@HOST#22222:/PATH" nil 1 10 nil))
  tramp-sh-file-name-handler(insert-file-contents "/ssh:USER@HOST#22222:/PATH" nil 1 10 nil)
  apply(tramp-sh-file-name-handler insert-file-contents ("/ssh:USER@HOST#22222:/PATH" nil 1 10 nil))
  tramp-file-name-handler(insert-file-contents "/ssh:USER@HOST#22222:/PATH" nil 1 10 nil)
  insert-file-contents("/ssh:USER@HOST#22222:/PATH" nil 1 10)
  (progn (insert-file-contents file nil 1 10))
  (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))
  (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))
  (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))
  (let ((file buffer-file-name)) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))
  eval((let ((file buffer-file-name)) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))) t)
  #f(compiled-function (exp &optional insert-value no-truncate char-print-limit) "Evaluate EXP and print value in the echo area.\nWhen called interactively, read an Emacs Lisp expression and\nevaluate it.  Value is also consed on to front of the variable\n`values'.  Optional argument INSERT-VALUE non-nil (interactively,\nwith a non `-' prefix argument) means insert the result into the\ncurrent buffer instead of printing it in the echo area.\n\nNormally, this function truncates long output according to the\nvalue of the variables `eval-expression-print-length' and\n`eval-expression-print-level'.  When NO-TRUNCATE is\nnon-nil (interactively, with a prefix argument of zero), however,\nthere is no such truncation.\n\nIf the resulting value is an integer, and CHAR-PRINT-LIMIT is\nnon-nil (interactively, unless given a non-zero prefix argument)\nit will be printed in several additional formats (octal,\nhexadecimal, and character).  The character format is used only\nif the value is below CHAR-PRINT-LIMIT (interactively, if the\nprefix argument is -1 or the value doesn't exceed\n`eval-expression-print-maximum-character').\n\nRuns the hook `eval-expression-minibuffer-setup-hook' on entering the\nminibuffer.\n\nIf `eval-expression-debug-on-error' is non-nil, which is the default,\nthis command arranges for all errors to enter the debugger." (interactive #f(compiled-function () #<bytecode -0x456f37b6488d2cd>)) #<bytecode 0x1eb79da7fc1b0212>)((let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127)
  apply(#f(compiled-function (exp &optional insert-value no-truncate char-print-limit) "Evaluate EXP and print value in the echo area.\nWhen called interactively, read an Emacs Lisp expression and\nevaluate it.  Value is also consed on to front of the variable\n`values'.  Optional argument INSERT-VALUE non-nil (interactively,\nwith a non `-' prefix argument) means insert the result into the\ncurrent buffer instead of printing it in the echo area.\n\nNormally, this function truncates long output according to the\nvalue of the variables `eval-expression-print-length' and\n`eval-expression-print-level'.  When NO-TRUNCATE is\nnon-nil (interactively, with a prefix argument of zero), however,\nthere is no such truncation.\n\nIf the resulting value is an integer, and CHAR-PRINT-LIMIT is\nnon-nil (interactively, unless given a non-zero prefix argument)\nit will be printed in several additional formats (octal,\nhexadecimal, and character).  The character format is used only\nif the value is below CHAR-PRINT-LIMIT (interactively, if the\nprefix argument is -1 or the value doesn't exceed\n`eval-expression-print-maximum-character').\n\nRuns the hook `eval-expression-minibuffer-setup-hook' on entering the\nminibuffer.\n\nIf `eval-expression-debug-on-error' is non-nil, which is the default,\nthis command arranges for all errors to enter the debugger." (interactive #f(compiled-function () #<bytecode -0x456f37b6488d2cd>)) #<bytecode 0x1eb79da7fc1b0212>) ((let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127))
  eval-expression((let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127)
  funcall-interactively(eval-expression (let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127)
  #<subr call-interactively>(eval-expression nil nil)
  apply(#<subr call-interactively> eval-expression (nil nil))
  call-interactively@ido-cr+-record-current-command(#<subr call-interactively> eval-expression nil nil)
  apply(call-interactively@ido-cr+-record-current-command #<subr call-interactively> (eval-expression nil nil))
  call-interactively(eval-expression nil nil)
  command-execute(eval-expression)

[-- Attachment #3: TRAMP-LOG --]
[-- Type: application/octet-stream, Size: 18432 bytes --]

;; Emacs: 29.0.50 Tramp: 2.6.0-pre -*- mode: outline; coding: utf-8; -*-
;; Location: /usr/local/share/emacs/29.0.50/lisp/net/tramp.elc Git: master/5fd8e1cc49d2ebd59219ddf3a691949a22b601f3
10:26:36.638086 tramp-handle-insert-file-contents (3) # Inserting ‘/ssh:USER@HOST#22222:/PATH’...
10:26:36.639033 tramp-get-connection-property (7) # remote-tmpdir undef; cache used: nil
10:26:36.639200 tramp-get-connection-property (7) # tmpdir /ssh:USER@HOST#22222:/tmp; cache used: t
10:26:36.639335 tramp-get-connection-property (7) # tmpdir /ssh:USER@HOST#22222:/tmp; cache used: t
10:26:36.770463 tramp-get-file-property (8) # /ssh:USER@HOST#22222:/tmp file-directory-p nil; inhibit: 600; cache used: t; cached at: 10:25:59
10:26:36.864494 tramp-get-remote-tmpdir (10) # 
  backtrace()
  tramp-error((tramp-file-name "ssh" "USER" nil "HOST" "22222" "/PATH" nil) file-error "Directory %s not accessible" "/ssh:USER@HOST#22222:/ssh:USER...")
  tramp-get-remote-tmpdir((tramp-file-name "ssh" "USER" nil "HOST" "22222" "/PATH" nil))
  tramp-make-tramp-temp-file((tramp-file-name "ssh" "USER" nil "HOST" "22222" "/PATH" nil))
  tramp-handle-insert-file-contents("/ssh:USER@HOST#22222:/PATH" nil 1 10 nil)
  apply(tramp-handle-insert-file-contents ("/ssh:USER@HOST#22222:/PATH" nil 1 10 nil))
  tramp-sh-file-name-handler(insert-file-contents "/ssh:USER@HOST#22222:/PATH" nil 1 10 nil)
  apply(tramp-sh-file-name-handler insert-file-contents ("/ssh:USER@HOST#22222:/PATH" nil 1 10 nil))
  tramp-file-name-handler(insert-file-contents "/ssh:USER@HOST#22222:/PATH" nil 1 10 nil)
  insert-file-contents("/ssh:USER@HOST#22222:/PATH" nil 1 10)
  (progn (insert-file-contents file nil 1 10))
  (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))
  (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))
  (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))
  (let ((file buffer-file-name)) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))
  eval((let ((file buffer-file-name)) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))) t)
  #f(compiled-function (exp &optional insert-value no-truncate char-print-limit) "Evaluate EXP and print value in the echo area.\nWhen called interactively, read an Emacs Lisp expression and\nevaluate it.  Value is also consed on to front of the variable\n`values'.  Optional argument INSERT-VALUE non-nil (interactively,\nwith a non `-' prefix argument) means insert the result into the\ncurrent buffer instead of printing it in the echo area.\n\nNormally, this function truncates long output according to the\nvalue of the variables `eval-expression-print-length' and\n`eval-expression-print-level'.  When NO-TRUNCATE is\nnon-nil (interactively, with a prefix argument of zero), however,\nthere is no such truncation.\n\nIf the resulting value is an integer, and CHAR-PRINT-LIMIT is\nnon-nil (interactively, unless given a non-zero prefix argument)\nit will be printed in several additional formats (octal,\nhexadecimal, and character).  The character format is used only\nif the value is below CHAR-PRINT-LIMIT (interactively, if the\nprefix argument is -1 or the value doesn't exceed\n`eval-expression-print-maximum-character').\n\nRuns the hook `eval-expression-minibuffer-setup-hook' on entering the\nminibuffer.\n\nIf `eval-expression-debug-on-error' is non-nil, which is the default,\nthis command arranges for all errors to enter the debugger." (interactive #f(compiled-function () #<bytecode -0x456f37b6488d2cd>)) #<bytecode 0x1eb79da7fc1b0212>)((let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127)
  apply(#f(compiled-function (exp &optional insert-value no-truncate char-print-limit) "Evaluate EXP and print value in the echo area.\nWhen called interactively, read an Emacs Lisp expression and\nevaluate it.  Value is also consed on to front of the variable\n`values'.  Optional argument INSERT-VALUE non-nil (interactively,\nwith a non `-' prefix argument) means insert the result into the\ncurrent buffer instead of printing it in the echo area.\n\nNormally, this function truncates long output according to the\nvalue of the variables `eval-expression-print-length' and\n`eval-expression-print-level'.  When NO-TRUNCATE is\nnon-nil (interactively, with a prefix argument of zero), however,\nthere is no such truncation.\n\nIf the resulting value is an integer, and CHAR-PRINT-LIMIT is\nnon-nil (interactively, unless given a non-zero prefix argument)\nit will be printed in several additional formats (octal,\nhexadecimal, and character).  The character format is used only\nif the value is below CHAR-PRINT-LIMIT (interactively, if the\nprefix argument is -1 or the value doesn't exceed\n`eval-expression-print-maximum-character').\n\nRuns the hook `eval-expression-minibuffer-setup-hook' on entering the\nminibuffer.\n\nIf `eval-expression-debug-on-error' is non-nil, which is the default,\nthis command arranges for all errors to enter the debugger." (interactive #f(compiled-function () #<bytecode -0x456f37b6488d2cd>)) #<bytecode 0x1eb79da7fc1b0212>) ((let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127))
  eval-expression((let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127)
  funcall-interactively(eval-expression (let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127)
  #<subr call-interactively>(eval-expression nil nil)
  apply(#<subr call-interactively> eval-expression (nil nil))
  call-interactively@ido-cr+-record-current-command(#<subr call-interactively> eval-expression nil nil)
  apply(call-interactively@ido-cr+-record-current-command #<subr call-interactively> (eval-expression nil nil))
  call-interactively(eval-expression nil nil)
  command-execute(eval-expression)
10:26:36.864700 tramp-get-remote-tmpdir (1) # File error: Directory /ssh:USER@HOST#22222:/ssh:USER@HOST#22222:/tmp not accessible
10:26:36.865093 tramp-handle-insert-file-contents (3) # Inserting ‘/ssh:USER@HOST#22222:/PATH’...failed
10:26:36.865894 tramp-get-file-property (8) # /PATH file-exists-p t; inhibit: 600; cache used: t; cached at: 10:25:59
10:26:36.937445 tramp-handle-insert-file-contents (10) # 
  backtrace()
  tramp-error((tramp-file-name "ssh" "USER" nil "HOST" "22222" "/PATH" nil) file-error "Directory /ssh:USER@HOST#22222:/ssh...")
  tramp-signal-hook-function(file-error ("Directory /ssh:USER@HOST#22222:/ssh..."))
  signal(file-error ("Directory /ssh:USER@HOST#22222:/ssh..."))
  tramp-handle-insert-file-contents("/ssh:USER@HOST#22222:/PATH" nil 1 10 nil)
  apply(tramp-handle-insert-file-contents ("/ssh:USER@HOST#22222:/PATH" nil 1 10 nil))
  tramp-sh-file-name-handler(insert-file-contents "/ssh:USER@HOST#22222:/PATH" nil 1 10 nil)
  apply(tramp-sh-file-name-handler insert-file-contents ("/ssh:USER@HOST#22222:/PATH" nil 1 10 nil))
  tramp-file-name-handler(insert-file-contents "/ssh:USER@HOST#22222:/PATH" nil 1 10 nil)
  insert-file-contents("/ssh:USER@HOST#22222:/PATH" nil 1 10)
  (progn (insert-file-contents file nil 1 10))
  (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))
  (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))
  (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))
  (let ((file buffer-file-name)) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))
  eval((let ((file buffer-file-name)) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))) t)
  #f(compiled-function (exp &optional insert-value no-truncate char-print-limit) "Evaluate EXP and print value in the echo area.\nWhen called interactively, read an Emacs Lisp expression and\nevaluate it.  Value is also consed on to front of the variable\n`values'.  Optional argument INSERT-VALUE non-nil (interactively,\nwith a non `-' prefix argument) means insert the result into the\ncurrent buffer instead of printing it in the echo area.\n\nNormally, this function truncates long output according to the\nvalue of the variables `eval-expression-print-length' and\n`eval-expression-print-level'.  When NO-TRUNCATE is\nnon-nil (interactively, with a prefix argument of zero), however,\nthere is no such truncation.\n\nIf the resulting value is an integer, and CHAR-PRINT-LIMIT is\nnon-nil (interactively, unless given a non-zero prefix argument)\nit will be printed in several additional formats (octal,\nhexadecimal, and character).  The character format is used only\nif the value is below CHAR-PRINT-LIMIT (interactively, if the\nprefix argument is -1 or the value doesn't exceed\n`eval-expression-print-maximum-character').\n\nRuns the hook `eval-expression-minibuffer-setup-hook' on entering the\nminibuffer.\n\nIf `eval-expression-debug-on-error' is non-nil, which is the default,\nthis command arranges for all errors to enter the debugger." (interactive #f(compiled-function () #<bytecode -0x456f37b6488d2cd>)) #<bytecode 0x1eb79da7fc1b0212>)((let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127)
  apply(#f(compiled-function (exp &optional insert-value no-truncate char-print-limit) "Evaluate EXP and print value in the echo area.\nWhen called interactively, read an Emacs Lisp expression and\nevaluate it.  Value is also consed on to front of the variable\n`values'.  Optional argument INSERT-VALUE non-nil (interactively,\nwith a non `-' prefix argument) means insert the result into the\ncurrent buffer instead of printing it in the echo area.\n\nNormally, this function truncates long output according to the\nvalue of the variables `eval-expression-print-length' and\n`eval-expression-print-level'.  When NO-TRUNCATE is\nnon-nil (interactively, with a prefix argument of zero), however,\nthere is no such truncation.\n\nIf the resulting value is an integer, and CHAR-PRINT-LIMIT is\nnon-nil (interactively, unless given a non-zero prefix argument)\nit will be printed in several additional formats (octal,\nhexadecimal, and character).  The character format is used only\nif the value is below CHAR-PRINT-LIMIT (interactively, if the\nprefix argument is -1 or the value doesn't exceed\n`eval-expression-print-maximum-character').\n\nRuns the hook `eval-expression-minibuffer-setup-hook' on entering the\nminibuffer.\n\nIf `eval-expression-debug-on-error' is non-nil, which is the default,\nthis command arranges for all errors to enter the debugger." (interactive #f(compiled-function () #<bytecode -0x456f37b6488d2cd>)) #<bytecode 0x1eb79da7fc1b0212>) ((let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127))
  eval-expression((let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127)
  funcall-interactively(eval-expression (let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127)
  #<subr call-interactively>(eval-expression nil nil)
  apply(#<subr call-interactively> eval-expression (nil nil))
  call-interactively@ido-cr+-record-current-command(#<subr call-interactively> eval-expression nil nil)
  apply(call-interactively@ido-cr+-record-current-command #<subr call-interactively> (eval-expression nil nil))
  call-interactively(eval-expression nil nil)
  command-execute(eval-expression)
10:26:36.937674 tramp-handle-insert-file-contents (1) # File error: Directory /ssh:USER@HOST#22222:/ssh:USER@HOST#22222:/tmp not accessible
10:26:36.999310 tramp-handle-insert-file-contents (10) # 
  backtrace()
  tramp-error((tramp-file-name "ssh" "USER" nil "HOST" "22222" "/PATH" nil) file-missing "/ssh:USER@HOST#22222:/PATH")
  tramp-handle-insert-file-contents("/ssh:USER@HOST#22222:/PATH" nil 1 10 nil)
  apply(tramp-handle-insert-file-contents ("/ssh:USER@HOST#22222:/PATH" nil 1 10 nil))
  tramp-sh-file-name-handler(insert-file-contents "/ssh:USER@HOST#22222:/PATH" nil 1 10 nil)
  apply(tramp-sh-file-name-handler insert-file-contents ("/ssh:USER@HOST#22222:/PATH" nil 1 10 nil))
  tramp-file-name-handler(insert-file-contents "/ssh:USER@HOST#22222:/PATH" nil 1 10 nil)
  insert-file-contents("/ssh:USER@HOST#22222:/PATH" nil 1 10)
  (progn (insert-file-contents file nil 1 10))
  (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))
  (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))
  (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))
  (let ((file buffer-file-name)) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))
  eval((let ((file buffer-file-name)) (let ((temp-buffer (generate-new-buffer " *temp*" t))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents file nil 1 10)) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))) t)
  #f(compiled-function (exp &optional insert-value no-truncate char-print-limit) "Evaluate EXP and print value in the echo area.\nWhen called interactively, read an Emacs Lisp expression and\nevaluate it.  Value is also consed on to front of the variable\n`values'.  Optional argument INSERT-VALUE non-nil (interactively,\nwith a non `-' prefix argument) means insert the result into the\ncurrent buffer instead of printing it in the echo area.\n\nNormally, this function truncates long output according to the\nvalue of the variables `eval-expression-print-length' and\n`eval-expression-print-level'.  When NO-TRUNCATE is\nnon-nil (interactively, with a prefix argument of zero), however,\nthere is no such truncation.\n\nIf the resulting value is an integer, and CHAR-PRINT-LIMIT is\nnon-nil (interactively, unless given a non-zero prefix argument)\nit will be printed in several additional formats (octal,\nhexadecimal, and character).  The character format is used only\nif the value is below CHAR-PRINT-LIMIT (interactively, if the\nprefix argument is -1 or the value doesn't exceed\n`eval-expression-print-maximum-character').\n\nRuns the hook `eval-expression-minibuffer-setup-hook' on entering the\nminibuffer.\n\nIf `eval-expression-debug-on-error' is non-nil, which is the default,\nthis command arranges for all errors to enter the debugger." (interactive #f(compiled-function () #<bytecode -0x456f37b6488d2cd>)) #<bytecode 0x1eb79da7fc1b0212>)((let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127)
  apply(#f(compiled-function (exp &optional insert-value no-truncate char-print-limit) "Evaluate EXP and print value in the echo area.\nWhen called interactively, read an Emacs Lisp expression and\nevaluate it.  Value is also consed on to front of the variable\n`values'.  Optional argument INSERT-VALUE non-nil (interactively,\nwith a non `-' prefix argument) means insert the result into the\ncurrent buffer instead of printing it in the echo area.\n\nNormally, this function truncates long output according to the\nvalue of the variables `eval-expression-print-length' and\n`eval-expression-print-level'.  When NO-TRUNCATE is\nnon-nil (interactively, with a prefix argument of zero), however,\nthere is no such truncation.\n\nIf the resulting value is an integer, and CHAR-PRINT-LIMIT is\nnon-nil (interactively, unless given a non-zero prefix argument)\nit will be printed in several additional formats (octal,\nhexadecimal, and character).  The character format is used only\nif the value is below CHAR-PRINT-LIMIT (interactively, if the\nprefix argument is -1 or the value doesn't exceed\n`eval-expression-print-maximum-character').\n\nRuns the hook `eval-expression-minibuffer-setup-hook' on entering the\nminibuffer.\n\nIf `eval-expression-debug-on-error' is non-nil, which is the default,\nthis command arranges for all errors to enter the debugger." (interactive #f(compiled-function () #<bytecode -0x456f37b6488d2cd>)) #<bytecode 0x1eb79da7fc1b0212>) ((let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127))
  eval-expression((let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127)
  funcall-interactively(eval-expression (let ((file buffer-file-name)) (with-temp-buffer (insert-file-contents file nil 1 10))) nil nil 127)
  #<subr call-interactively>(eval-expression nil nil)
  apply(#<subr call-interactively> eval-expression (nil nil))
  call-interactively@ido-cr+-record-current-command(#<subr call-interactively> eval-expression nil nil)
  apply(call-interactively@ido-cr+-record-current-command #<subr call-interactively> (eval-expression nil nil))
  call-interactively(eval-expression nil nil)
  command-execute(eval-expression)
10:26:36.999890 tramp-handle-insert-file-contents (1) # File is missing: /ssh:USER@HOST#22222:/PATH

  reply	other threads:[~2022-09-30  8:49 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-14 12:11 bug#57800: TRAMP insert-file-contents now fails for regions Paul Pogonyshev
2022-09-14 18:08 ` Lars Ingebrigtsen
2022-09-14 18:18   ` Paul Pogonyshev
2022-09-14 18:23     ` Lars Ingebrigtsen
2022-09-14 18:33       ` Paul Pogonyshev
2022-09-15 10:30         ` Michael Albinus
2022-09-16  9:37           ` Lars Ingebrigtsen
2022-09-29  9:24             ` Paul Pogonyshev
2022-09-29 10:43               ` Lars Ingebrigtsen
2022-09-29 11:26                 ` Paul Pogonyshev
2022-09-29 11:27                   ` Paul Pogonyshev
2022-09-29 17:39                   ` Michael Albinus
2022-09-30  8:49                     ` Paul Pogonyshev [this message]
2022-09-30 18:39                       ` Michael Albinus
2022-09-30 18:52                         ` Paul Pogonyshev
2022-09-30 19:11                           ` Michael Albinus
2022-09-30 19:58                             ` Michael Albinus
2022-09-30 20:48                               ` Paul Pogonyshev
2022-10-01 15:18                                 ` Michael Albinus
2022-10-01 16:16                                   ` Paul Pogonyshev

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAG7BpapCHdakyC8NaYJ9F_Cio6ZBQjmK2b0mLnYJYz3ND24wqg@mail.gmail.com \
    --to=pogonyshev@gmail.com \
    --cc=57800@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    --cc=michael.albinus@gmx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.