unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#34610: 27.0.50; wdired gets rename file and directory errors when using gls and -F or --classify switch
@ 2019-02-21 22:31 Jeffrey Spencer
  2019-04-26 23:58 ` Basil L. Contovounesios
  2019-08-24  0:52 ` Stefan Kangas
  0 siblings, 2 replies; 6+ messages in thread
From: Jeffrey Spencer @ 2019-02-21 22:31 UTC (permalink / raw)
  To: 34610

[-- Attachment #1: Type: text/plain, Size: 5527 bytes --]

This is the only setup besides -Q default:
(setq insert-directory-program "gls" dired-use-ls-dired t)
(setq dired-listing-switches "-a --classify -lGhHA
--group-directories-first")
"-a --classify -lGhHA  --group-directories-first"

Renaming directories doesn't work right due to the --classify (-F) switches
using gls on Mac. Also, probably has problems with executables due to
adding '*' to the end of the file name but I didn't check. I had to right
an advice around wdired-change-mode to remove the switches and then re-add
the -F --classify.

Here is the errors with just a simple truing to add a character to any
directory:

Rename ‘/Users/Me/Downloads/youtube/test/k’ to
‘/Users/Me/Downloads/youtube/test/k/’ failed:
(file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/k
/Users/Me/Downloads/youtube/test/k/k)
Rename ‘/Users/Me/Downloads/youtube/test/kdkd’ to
‘/Users/Me/Downloads/youtube/test/kdkd/’ failed:
(file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/kdkd
/Users/Me/Downloads/youtube/test/kdkd/kdkd)
Rename ‘/Users/Me/Downloads/youtube/test/l’ to
‘/Users/Me/Downloads/youtube/test/l/’ failed:
(file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/l
/Users/Me/Downloads/youtube/test/l/l)
Rename ‘/Users/Me/Downloads/youtube/test/kdkd/kdk’ to
‘/Users/Me/Downloads/youtube/test/kdkd/kdk/’ failed:
(file-error Renaming Invalid argument
/Users/Me/Downloads/youtube/test/kdkd/kdk
/Users/Me/Downloads/youtube/test/kdkd/kdk/kdk)

4 rename actions failed

In GNU Emacs 27.0.50 (build 1, x86_64-apple-darwin15.6.0, NS appkit-1404.47
Version 10.11.6 (Build 15G22010))
of 2019-02-20 built on Jeffs-MacBook-Pro-2.local
Repository revision: 0a6c4479cff17b487580abe3a7ee202e71be25d2
Repository branch: master
Windowing system distributor 'Apple', version 10.3.1404
System Description:  Mac OS X 10.11.6

Recent messages:
C-c C-p is undefined
Press C-c C-c when finished or C-c ESC to abort changes
dired-create-directory: Cannot create directory
/Users/bigtyme/Downloads/youtube/test/kdkd: file exists
Press C-c C-c when finished or C-c ESC to abort changes
Creating directory for file /Users/bigtyme/Downloads/youtube/test/k/blah/
3 rename actions failed--type ? for details
Press C-c C-c when finished or C-c ESC to abort changes
3 rename actions failed--type ? for details
Press C-c C-c when finished or C-c ESC to abort changes
3 rename actions failed--type ? for details

Configured using:
'configure --disable-dependency-tracking --disable-silent-rules
--enable-locallisppath=/usr/local/share/emacs/site-lisp
--infodir=/usr/local/Cellar/emacs-plus/HEAD-0a6c447/share/info/emacs
--prefix=/usr/local/Cellar/emacs-plus/HEAD-0a6c447 --with-xml2
--without-dbus --with-gnutls --with-imagemagick --with-modules
--with-rsvg --with-ns --disable-ns-self-contained'

Configured features:
RSVG IMAGEMAGICK GLIB NOTIFY KQUEUE ACL GNUTLS LIBXML2 ZLIB
TOOLKIT_SCROLL_BARS NS MODULES THREADS PDUMPER LCMS2 GMP

Important settings:
 value of $LANG: en_AU.UTF-8
 locale-coding-system: utf-8-unix

Major mode: Dired

Minor modes in effect:
 tooltip-mode: t
 global-eldoc-mode: t
 electric-indent-mode: t
 mouse-wheel-mode: t
 tool-bar-mode: t
 menu-bar-mode: t
 file-name-shadow-mode: t
 global-font-lock-mode: t
 font-lock-mode: t
 blink-cursor-mode: t
 auto-composition-mode: t
 auto-encryption-mode: t
 auto-compression-mode: t
 buffer-read-only: t
 line-number-mode: t
 transient-mark-mode: t

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug sendmail wdired dired-aux mm-archive
message dired dired-loaddefs format-spec rfc822 mml mml-sec epa derived
gnus-util rmail rmail-loaddefs time-date mailabbrev gmm-utils mailheader
mm-decode mm-bodies mm-encode mail-utils gnutls network-stream url-http
mail-parse rfc2231 rfc2047 rfc2045 mm-util ietf-drums mail-prsvr url-gw
nsm rmc puny url-cache url-auth url url-proxy url-privacy url-expand
url-methods url-history url-cookie url-domsuf url-util mailcap epg
finder-inf package easymenu epg-config url-handlers url-parse
auth-source cl-seq eieio eieio-core cl-macs eieio-loaddefs
password-cache json map url-vars seq byte-opt gv bytecomp byte-compile
cconv cl-loaddefs cl-lib elec-pair tooltip eldoc electric uniquify
ediff-hook vc-hooks lisp-float-type mwheel term/ns-win ns-win
ucs-normalize mule-util term/common-win tool-bar dnd fontset image
regexp-opt fringe tabulated-list replace newcomment text-mode elisp-mode
lisp-mode prog-mode register page menu-bar rfn-eshadow isearch timer
select scroll-bar mouse jit-lock font-lock syntax facemenu font-core
term/tty-colors frame cl-generic cham georgian utf-8-lang misc-lang
vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932
hebrew greek romanian slovak czech european ethiopic indian cyrillic
chinese composite charscript charprop case-table epa-hook jka-cmpr-hook
help simple abbrev obarray minibuffer cl-preloaded 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 threads kqueue cocoa ns lcms2 multi-tty make-network-process
emacs)

Memory information:
((conses 16 67245 11725)
(symbols 48 8118 1)
(strings 32 22680 2213)
(string-bytes 1 762050)
(vectors 16 12430)
(vector-slots 8 151079 17144)
(floats 8 18 181)
(intervals 56 554 0)
(buffers 992 17))

[-- Attachment #2: Type: text/html, Size: 6033 bytes --]

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

* bug#34610: 27.0.50; wdired gets rename file and directory errors when using gls and -F or --classify switch
  2019-02-21 22:31 bug#34610: 27.0.50; wdired gets rename file and directory errors when using gls and -F or --classify switch Jeffrey Spencer
@ 2019-04-26 23:58 ` Basil L. Contovounesios
  2019-05-30 12:12   ` Basil L. Contovounesios
  2019-08-24  0:52 ` Stefan Kangas
  1 sibling, 1 reply; 6+ messages in thread
From: Basil L. Contovounesios @ 2019-04-26 23:58 UTC (permalink / raw)
  To: Jeffrey Spencer; +Cc: 34610

Jeffrey Spencer <jeffspencerd@gmail.com> writes:

> This is the only setup besides -Q default:
> (setq insert-directory-program "gls" dired-use-ls-dired t)
> (setq dired-listing-switches "-a --classify -lGhHA  --group-directories-first")
> "-a --classify -lGhHA  --group-directories-first"
>
> Renaming directories doesn't work right due to the --classify (-F)
> switches using gls on Mac. Also, probably has problems with
> executables due to adding '*' to the end of the file name but I didn't
> check. I had to right an advice around wdired-change-mode to remove
> the switches and then re-add the -F --classify.
>
> Here is the errors with just a simple truing to add a character to any directory:
>
> Rename ‘/Users/Me/Downloads/youtube/test/k’ to ‘/Users/Me/Downloads/youtube/test/k/’ failed:
> (file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/k /Users/Me/Downloads/youtube/test/k/k)
> Rename ‘/Users/Me/Downloads/youtube/test/kdkd’ to ‘/Users/Me/Downloads/youtube/test/kdkd/’ failed:
> (file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/kdkd /Users/Me/Downloads/youtube/test/kdkd/kdkd)
> Rename ‘/Users/Me/Downloads/youtube/test/l’ to ‘/Users/Me/Downloads/youtube/test/l/’ failed:
> (file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/l /Users/Me/Downloads/youtube/test/l/l)
> Rename ‘/Users/Me/Downloads/youtube/test/kdkd/kdk’ to ‘/Users/Me/Downloads/youtube/test/kdkd/kdk/’ failed:
> (file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/kdkd/kdk /Users/Me/Downloads/youtube/test/kdkd/kdk/kdk)
>
> 4 rename actions failed

This sounds similar to bug#34915[1], whose fix was recently pushed to
master[2].  Can you please check whether that also fixes your issue?  If
so, I will merge the two reports as duplicate.

[1]: https://debbugs.gnu.org/34915

[2: 6d8e0fc5aa]: Make wdired-mode ignore ls file indicators
  2019-04-25 19:17:23 +0200
  https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=6d8e0fc5aa7673540486af9ecbfc0a3e23c305cf

Thanks,

-- 
Basil





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

* bug#34610: 27.0.50; wdired gets rename file and directory errors when using gls and -F or --classify switch
  2019-04-26 23:58 ` Basil L. Contovounesios
@ 2019-05-30 12:12   ` Basil L. Contovounesios
       [not found]     ` <CALmFPZ2LYLo_t81NOvyLndiL8WC87VMQ46naGzNHjOKHrugjZA@mail.gmail.com>
  0 siblings, 1 reply; 6+ messages in thread
From: Basil L. Contovounesios @ 2019-05-30 12:12 UTC (permalink / raw)
  To: Jeffrey Spencer; +Cc: 34610

Ping!

"Basil L. Contovounesios" <contovob@tcd.ie> writes:

> Jeffrey Spencer <jeffspencerd@gmail.com> writes:
>
>> This is the only setup besides -Q default:
>> (setq insert-directory-program "gls" dired-use-ls-dired t)
>> (setq dired-listing-switches "-a --classify -lGhHA  --group-directories-first")
>> "-a --classify -lGhHA  --group-directories-first"
>>
>> Renaming directories doesn't work right due to the --classify (-F)
>> switches using gls on Mac. Also, probably has problems with
>> executables due to adding '*' to the end of the file name but I didn't
>> check. I had to right an advice around wdired-change-mode to remove
>> the switches and then re-add the -F --classify.
>>
>> Here is the errors with just a simple truing to add a character to any directory:
>>
>> Rename ‘/Users/Me/Downloads/youtube/test/k’ to ‘/Users/Me/Downloads/youtube/test/k/’ failed:
>> (file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/k
>> /Users/Me/Downloads/youtube/test/k/k)
>> Rename ‘/Users/Me/Downloads/youtube/test/kdkd’ to
>> ‘/Users/Me/Downloads/youtube/test/kdkd/’ failed:
>> (file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/kdkd
>> /Users/Me/Downloads/youtube/test/kdkd/kdkd)
>> Rename ‘/Users/Me/Downloads/youtube/test/l’ to ‘/Users/Me/Downloads/youtube/test/l/’ failed:
>> (file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/l
>> /Users/Me/Downloads/youtube/test/l/l)
>> Rename ‘/Users/Me/Downloads/youtube/test/kdkd/kdk’ to
>> ‘/Users/Me/Downloads/youtube/test/kdkd/kdk/’ failed:
>> (file-error Renaming Invalid argument
>> /Users/Me/Downloads/youtube/test/kdkd/kdk
>> /Users/Me/Downloads/youtube/test/kdkd/kdk/kdk)
>>
>> 4 rename actions failed
>
> This sounds similar to bug#34915[1], whose fix was recently pushed to
> master[2].  Can you please check whether that also fixes your issue?  If
> so, I will merge the two reports as duplicate.
>
> [1]: https://debbugs.gnu.org/34915
>
> [2: 6d8e0fc5aa]: Make wdired-mode ignore ls file indicators
>   2019-04-25 19:17:23 +0200
>   https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=6d8e0fc5aa7673540486af9ecbfc0a3e23c305cf

-- 
Basil





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

* bug#34610: 27.0.50; wdired gets rename file and directory errors when using gls and -F or --classify switch
       [not found]     ` <CALmFPZ2LYLo_t81NOvyLndiL8WC87VMQ46naGzNHjOKHrugjZA@mail.gmail.com>
@ 2019-05-30 13:02       ` Basil L. Contovounesios
  2019-05-30 17:40         ` Jeffrey Spencer
  0 siblings, 1 reply; 6+ messages in thread
From: Basil L. Contovounesios @ 2019-05-30 13:02 UTC (permalink / raw)
  To: Jeffrey Spencer; +Cc: 34610

Jeffrey Spencer <jeffspencerd@gmail.com> writes:

> Sorry, I installed from HEAD awhile ago to fix a problem with magit,
> but haven't been able to update to the current head to test again as I
> patched it with an advice currently. I will try to update to Head this
> week then let you know.

Great, just be sure to select "Reply All" in your next message, so that
the bug address 34610@debbugs.gnu.org is included in the To: or Cc:
header and others reading this bug report can see it as well.

TIA,

-- 
Basil





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

* bug#34610: 27.0.50; wdired gets rename file and directory errors when using gls and -F or --classify switch
  2019-05-30 13:02       ` Basil L. Contovounesios
@ 2019-05-30 17:40         ` Jeffrey Spencer
  0 siblings, 0 replies; 6+ messages in thread
From: Jeffrey Spencer @ 2019-05-30 17:40 UTC (permalink / raw)
  To: Basil L. Contovounesios; +Cc: 34610

[-- Attachment #1: Type: text/plain, Size: 1036 bytes --]

The fix appears to work fine in my testing on a emacs -Q with just the
switches. I didn't remove my advice around the call to wdired to test in my
own setup because now I like that the classify switches and executable
marks are removed, since this just seems to make that text unwritable. It
makes editing multiple files with multiple-curosrs much easier if these
extra characters aren't there for me in wdired.

On Thu, May 30, 2019 at 10:02 PM Basil L. Contovounesios <contovob@tcd.ie>
wrote:

> Jeffrey Spencer <jeffspencerd@gmail.com> writes:
>
> > Sorry, I installed from HEAD awhile ago to fix a problem with magit,
> > but haven't been able to update to the current head to test again as I
> > patched it with an advice currently. I will try to update to Head this
> > week then let you know.
>
> Great, just be sure to select "Reply All" in your next message, so that
> the bug address 34610@debbugs.gnu.org is included in the To: or Cc:
> header and others reading this bug report can see it as well.
>
> TIA,
>
> --
> Basil
>

[-- Attachment #2: Type: text/html, Size: 1518 bytes --]

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

* bug#34610: 27.0.50; wdired gets rename file and directory errors when using gls and -F or --classify switch
  2019-02-21 22:31 bug#34610: 27.0.50; wdired gets rename file and directory errors when using gls and -F or --classify switch Jeffrey Spencer
  2019-04-26 23:58 ` Basil L. Contovounesios
@ 2019-08-24  0:52 ` Stefan Kangas
  1 sibling, 0 replies; 6+ messages in thread
From: Stefan Kangas @ 2019-08-24  0:52 UTC (permalink / raw)
  To: Basil L. Contovounesios; +Cc: Jeffrey Spencer, 34610

"Basil L. Contovounesios" <contovob@tcd.ie> writes:

> Jeffrey Spencer <jeffspencerd@gmail.com> writes:
>
>> This is the only setup besides -Q default:
>> (setq insert-directory-program "gls" dired-use-ls-dired t)
>> (setq dired-listing-switches "-a --classify -lGhHA  --group-directories-first")
>> "-a --classify -lGhHA  --group-directories-first"
>>
>> Renaming directories doesn't work right due to the --classify (-F)
>> switches using gls on Mac. Also, probably has problems with
>> executables due to adding '*' to the end of the file name but I didn't
>> check. I had to right an advice around wdired-change-mode to remove
>> the switches and then re-add the -F --classify.
>>
>> Here is the errors with just a simple truing to add a character to any directory:
>>
>> Rename ‘/Users/Me/Downloads/youtube/test/k’ to ‘/Users/Me/Downloads/youtube/test/k/’ failed:
>> (file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/k /Users/Me/Downloads/youtube/test/k/k)
>> Rename ‘/Users/Me/Downloads/youtube/test/kdkd’ to ‘/Users/Me/Downloads/youtube/test/kdkd/’ failed:
>> (file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/kdkd /Users/Me/Downloads/youtube/test/kdkd/kdkd)
>> Rename ‘/Users/Me/Downloads/youtube/test/l’ to ‘/Users/Me/Downloads/youtube/test/l/’ failed:
>> (file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/l /Users/Me/Downloads/youtube/test/l/l)
>> Rename ‘/Users/Me/Downloads/youtube/test/kdkd/kdk’ to ‘/Users/Me/Downloads/youtube/test/kdkd/kdk/’ failed:
>> (file-error Renaming Invalid argument /Users/Me/Downloads/youtube/test/kdkd/kdk /Users/Me/Downloads/youtube/test/kdkd/kdk/kdk)
>>
>> 4 rename actions failed
>
> This sounds similar to bug#34915[1], whose fix was recently pushed to
> master[2].  Can you please check whether that also fixes your issue?  If
> so, I will merge the two reports as duplicate.

I'm seeing a failure in the test suite on current master on MacOS that
does not show up on my Debian GNU/Linux system.  The failing test is
the test case for Bug#34915.

(Shell command succeeded with no output)
Connection file
"/var/folders/pj/rhx0gxy15tv3vx6l3mdy0qvm0000gn/T/test-dir-nheUrY/server"
deleted
Press C-c C-c when finished or C-c ESC to abort changes
1 rename actions failed--type ? for details
Connection file
"/var/folders/pj/rhx0gxy15tv3vx6l3mdy0qvm0000gn/T/test-dir-nheUrY/server"
deleted
Test wdired-test-bug34915 backtrace:
  signal(ert-test-failed (((should (equal dir (pop names))) :form (equ
  ert-fail(((should (equal dir (pop names))) :form (equal "bar@" "wbar
  #f(compiled-function () #<bytecode 0x1fec25c0680d>)()
  ert--run-test-internal(#s(ert--test-execution-info :test #s(ert-test
  ert-run-test(#s(ert-test :name wdired-test-bug34915 :documentation "
  ert-run-or-rerun-test(#s(ert--stats :selector (not (or ... ...)) :te
  ert-run-tests((not (or (tag :expensive-test) (tag :unstable))) #f(co
  ert-run-tests-batch((not (or (tag :expensive-test) (tag :unstable)))
  ert-run-tests-batch-and-exit((not (or (tag :expensive-test) (tag :un
  eval((ert-run-tests-batch-and-exit '(not (or (tag :expensive-test) (
  command-line-1(("-L" ":." "-l" "ert" "-l" "lisp/wdired-tests" "--eva
  command-line()
  normal-top-level()
Test wdired-test-bug34915 condition:
    (ert-test-failed
     ((should
       (equal dir
          (pop names)))
      :form
      (equal "bar@" "wbar@")
      :value nil :explanation
      (arrays-of-different-length 4 5 "bar@" "wbar@" first-mismatch-at 0)))
   FAILED  3/5  wdired-test-bug34915 (0.065950 sec)

When I test manually using the flags "-lF", I'm unable to rename a
symlink in wdired and get this error:

   "1 rename actions failed--type ? for details"

I'm using the stock ls from BSD.  Here's the difference in output from
GNU ls and BSD ls on my two machines:

macos$ mkdir tmp
macos$ cd tmp
macos$ touch a
macos$ ln -s a b
macos$ ls -lF
total 8
-rw-r--r--  1 skangas  staff  0 Aug 24 02:41 a
lrwxr-xr-x  1 skangas  staff  1 Aug 24 02:41 b@ -> a
macos$

debian$ mkdir tmp
debian$ cd tmp
debian$ touch a
debian$ ln -s a b
debian$ ls -lF
total 0
-rw-r--r-- 1 skangas skangas 0 Aug 24 02:42 a
lrwxr-xr-x 1 skangas skangas 1 Aug 24 02:42 b -> a
debian$

AFAICT, the difference is that the BSD ls appends an @ character to
the file name, which wdired incorrectly interprets as part of the file
name.

Thanks,
Stefan Kangas





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

end of thread, other threads:[~2019-08-24  0:52 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-21 22:31 bug#34610: 27.0.50; wdired gets rename file and directory errors when using gls and -F or --classify switch Jeffrey Spencer
2019-04-26 23:58 ` Basil L. Contovounesios
2019-05-30 12:12   ` Basil L. Contovounesios
     [not found]     ` <CALmFPZ2LYLo_t81NOvyLndiL8WC87VMQ46naGzNHjOKHrugjZA@mail.gmail.com>
2019-05-30 13:02       ` Basil L. Contovounesios
2019-05-30 17:40         ` Jeffrey Spencer
2019-08-24  0:52 ` Stefan Kangas

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).