unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#11902: Emacs 23.2: dired rename file and file is hidden - Windows 7
@ 2012-07-10 17:43 Bernard Stumpf
  2012-07-11 16:02 ` Eli Zaretskii
  0 siblings, 1 reply; 10+ messages in thread
From: Bernard Stumpf @ 2012-07-10 17:43 UTC (permalink / raw)
  To: 11902

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

Running emacs 23.2 on Windows 7 Home Premium SP1 on a Toshiba Satellite 
P740.

Doing a dired R filename newname
   after this the Dired buffer  does not have the line with newname and 
not filename either.
   Typing l (= dired-do-redisplay) and the line with newname shows up. 
Same thing by typing g (= revert-buffer)

In other words: the rename happens in the filesystem but the dired 
buffer display is incorrect - it looses or hides the renamed item.

I've run the same verson of emacs (23.2) on a Windows XP Pro SP3 earlier 
this year, and this dired problem was not observed.

-Bernard Stumpf

In GNU Emacs 23.2.1 (i386-mingw-nt6.1.7601)
 of 2010-05-08 on G41R2F1
Windowing system distributor `Microsoft Corp.', version 6.1.7601
configured using `configure --with-gcc (3.4) --no-opt --cflags 
-Ic:/xpm/include'

Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: ENU
  value of $XMODIFIERS: nil
  locale-coding-system: cp1252
  default enable-multibyte-characters: t

Major mode: Dired by date

Minor modes in effect:
  display-time-mode: t
  tooltip-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-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t

Load-path shadows:
None found.


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

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

* bug#11902: Emacs 23.2: dired rename file and file is hidden - Windows 7
  2012-07-10 17:43 bug#11902: Emacs 23.2: dired rename file and file is hidden - Windows 7 Bernard Stumpf
@ 2012-07-11 16:02 ` Eli Zaretskii
       [not found]   ` <4FFDB03B.5060906@verizon.net>
  0 siblings, 1 reply; 10+ messages in thread
From: Eli Zaretskii @ 2012-07-11 16:02 UTC (permalink / raw)
  To: Bernard Stumpf; +Cc: 11902

> Date: Tue, 10 Jul 2012 13:43:15 -0400
> From: Bernard Stumpf <bernard.stumpf@verizon.net>
> 
> Running emacs 23.2 on Windows 7 Home Premium SP1 on a Toshiba Satellite 
> P740.
> 
> Doing a dired R filename newname
>    after this the Dired buffer  does not have the line with newname and 
> not filename either.
>    Typing l (= dired-do-redisplay) and the line with newname shows up. 
> Same thing by typing g (= revert-buffer)
> 
> In other words: the rename happens in the filesystem but the dired 
> buffer display is incorrect - it looses or hides the renamed item.

I couldn't reproduce this, neither with Emacs 23.2 nor with the
current version.  The directory display refreshes automatically for
me.

Does the problem happen for you with every file, on every filesystem
to which you have access?  Or just certain files (or types of files)
are prone to this?

IOW, please tell more details about the problem, as it seems to be not
trivial to reproduce.





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

* bug#11902: Emacs 23.2: dired rename file and file is hidden - Windows 7
       [not found]   ` <4FFDB03B.5060906@verizon.net>
@ 2012-07-11 17:46     ` Eli Zaretskii
  2012-07-12  0:05       ` Bernard Stumpf
  0 siblings, 1 reply; 10+ messages in thread
From: Eli Zaretskii @ 2012-07-11 17:46 UTC (permalink / raw)
  To: Bernard Stumpf; +Cc: 11902

[Please CC the bug address on all your responses, so that this
discussion gets archived by the bug tracker.]

> Date: Wed, 11 Jul 2012 12:56:27 -0400
> From: Bernard Stumpf <bernard.stumpf@verizon.net>
> 
> As I stated before, I did not observe this problem on an IBM Thinkpad 
> running Windows XP Pro SP3.
> Now I'm using a Toshiba Satellite P740 running Windows 7 Home Premium SP1

I tried on Windows 7, and didn't see the problem.

> The problem has shown up on every rename in a dired buffer on this machine.

Strange, it doesn't happen for me.  Do you see that in "emacs -Q"?





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

* bug#11902: Emacs 23.2: dired rename file and file is hidden - Windows 7
  2012-07-11 17:46     ` Eli Zaretskii
@ 2012-07-12  0:05       ` Bernard Stumpf
  2012-07-12  5:15         ` Eli Zaretskii
  0 siblings, 1 reply; 10+ messages in thread
From: Bernard Stumpf @ 2012-07-12  0:05 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 11902

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

I just tried it in an "emacs -Q" window. Did a dired of my Users home 
directory and there did an R of an existing file to "newname".  The line 
containing the file disappeared.

In other words: "emacs -Q" made no difference: the problem remains.

-Bernie


Eli Zaretskii wrote at 13:46:

>[Please CC the bug address on all your responses, so that this
>discussion gets archived by the bug tracker.]
>
>  
>
>>Date: Wed, 11 Jul 2012 12:56:27 -0400
>>From: Bernard Stumpf <bernard.stumpf@verizon.net>
>>
>>As I stated before, I did not observe this problem on an IBM Thinkpad 
>>running Windows XP Pro SP3.
>>Now I'm using a Toshiba Satellite P740 running Windows 7 Home Premium SP1
>>    
>>
>
>I tried on Windows 7, and didn't see the problem.
>
>  
>
>>The problem has shown up on every rename in a dired buffer on this machine.
>>    
>>
>
>Strange, it doesn't happen for me.  Do you see that in "emacs -Q"?
>
>
>  
>

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

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

* bug#11902: Emacs 23.2: dired rename file and file is hidden - Windows 7
  2012-07-12  0:05       ` Bernard Stumpf
@ 2012-07-12  5:15         ` Eli Zaretskii
  2012-07-12 11:54           ` Bernard Stumpf
  0 siblings, 1 reply; 10+ messages in thread
From: Eli Zaretskii @ 2012-07-12  5:15 UTC (permalink / raw)
  To: Bernard Stumpf; +Cc: 11902

> Date: Wed, 11 Jul 2012 20:05:25 -0400
> From: Bernard Stumpf <bernard.stumpf@verizon.net>
> CC:  11902@debbugs.gnu.org
> 
> I just tried it in an "emacs -Q" window. Did a dired of my Users home 
> directory and there did an R of an existing file to "newname".  The line 
> containing the file disappeared.
> 
> In other words: "emacs -Q" made no difference: the problem remains.

Thanks.

Does the "newname" affect the problem?  E.g., if you rename file "foo"
to "foo1", does the problem still happen?

Also, can you perhaps debug this in Edebug?  I can provide guidance if
needed.  The function that refreshes the display is
dired-do-redisplay, defined on dired-aux.el, and the actual refresh of
the line of the affected file is in dired-update-file-line, also in
dired-aux.el.  Just step through these two functions and see what is
going wrong there and where.





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

* bug#11902: Emacs 23.2: dired rename file and file is hidden - Windows 7
  2012-07-12  5:15         ` Eli Zaretskii
@ 2012-07-12 11:54           ` Bernard Stumpf
  2012-07-12 12:47             ` Eli Zaretskii
  0 siblings, 1 reply; 10+ messages in thread
From: Bernard Stumpf @ 2012-07-12 11:54 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 11902

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

I have not noticed any sensitivity to the characters in "newname". I 
just created a file named "foo" and did an R to "foo1" - the line 
disappeared.

I did the same with file "bar" to "bar1". Here's output in *Messages*
...
(New file)
Saving file c:/Users/bernie/bar...
Wrote c:/Users/bernie/bar
Overwrite `c:/Users/bernie/bar'? [Type yn!q or C-h]  [5 times]
Quit
Move: 1 of 1
Move: 1 file
...

As to using Edebug: I don't know Edebug.  Is there a way to set 
breakpoints inside emacs from emacs?

-Bernie


Eli Zaretskii wrote at 01:15:

>>Date: Wed, 11 Jul 2012 20:05:25 -0400
>>From: Bernard Stumpf <bernard.stumpf@verizon.net>
>>CC:  11902@debbugs.gnu.org
>>
>>I just tried it in an "emacs -Q" window. Did a dired of my Users home 
>>directory and there did an R of an existing file to "newname".  The line 
>>containing the file disappeared.
>>
>>In other words: "emacs -Q" made no difference: the problem remains.
>>    
>>
>
>Thanks.
>
>Does the "newname" affect the problem?  E.g., if you rename file "foo"
>to "foo1", does the problem still happen?
>
>Also, can you perhaps debug this in Edebug?  I can provide guidance if
>needed.  The function that refreshes the display is
>dired-do-redisplay, defined on dired-aux.el, and the actual refresh of
>the line of the affected file is in dired-update-file-line, also in
>dired-aux.el.  Just step through these two functions and see what is
>going wrong there and where.
>
>
>  
>

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

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

* bug#11902: Emacs 23.2: dired rename file and file is hidden - Windows 7
  2012-07-12 11:54           ` Bernard Stumpf
@ 2012-07-12 12:47             ` Eli Zaretskii
  2012-07-12 13:30               ` Bernard Stumpf
  0 siblings, 1 reply; 10+ messages in thread
From: Eli Zaretskii @ 2012-07-12 12:47 UTC (permalink / raw)
  To: Bernard Stumpf; +Cc: 11902

> Date: Thu, 12 Jul 2012 07:54:07 -0400
> From: Bernard Stumpf <bernard.stumpf@verizon.net>
> CC:  11902@debbugs.gnu.org
> 
> I have not noticed any sensitivity to the characters in "newname". I 
> just created a file named "foo" and did an R to "foo1" - the line 
> disappeared.

OK.

> I did the same with file "bar" to "bar1". Here's output in *Messages*
> ...
> (New file)
> Saving file c:/Users/bernie/bar...
> Wrote c:/Users/bernie/bar
> Overwrite `c:/Users/bernie/bar'? [Type yn!q or C-h]  [5 times]

Any idea what that "Overwrite" message was about?

> As to using Edebug: I don't know Edebug.  Is there a way to set 
> breakpoints inside emacs from emacs?

Edebug _is_ used from inside Emacs.  For example, to step through
dired-do-redisplay and dired-update-file-line, you do this:

  emacs -Q
  M-x load-library dired-aux.el RET
  C-x d some/directory RET
  C-x C-f path/to/dired-aux.el RET
  go to the function dired-do-redisplay
  with cursor inside dired-do-redisplay's body, type:
    M-x edebug-defun RET

This instruments dired-do-redisplay, such that when it is called, the
debugger kicks in automatically.  Think if this as a kind of a
breakpoint you set on the function.

Now, go to the Dired buffer to the line of the file you want to rename
and press "R".  Emacs will pop up a window with the source of
dired-do-redisplay, with a small arrow at the left showing the current
line.  Typing SPC repeatedly will step through the code one Lisp form
at a time, and will also show in the echo area the result of
evaluating each form, so you can track what Emacs does and why.  To
step into dired-update-file-line, type 'i' when you get just before
the form that calls that function; then step through
dired-update-file-line by repeatedly typing SPC again.

Easy enough, isn't it?

From what you describe, I'd expect that dired-update-file-line deletes
the line of the file being renamed, but then doesn't add the line for
the new file, for some reason.  The addition is done by
dired-add-entry, which dired-update-file-line calls; you can step into
it by typing 'i' again.

The information you obtain by stepping through these functions will
probably get us much closer to resolving the problem, if not point out
the problem right away.

And just for the record: the way to reproduce the problem on that
machine is just the following sequence, and nothing else, right?

  emacs -Q
  C-x d RET
  go to some file
  type R foo RET

There's nothing else you do except the above sequence, correct?

Thanks.





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

* bug#11902: Emacs 23.2: dired rename file and file is hidden - Windows 7
  2012-07-12 12:47             ` Eli Zaretskii
@ 2012-07-12 13:30               ` Bernard Stumpf
  2019-10-31  0:53                 ` Stefan Kangas
  0 siblings, 1 reply; 10+ messages in thread
From: Bernard Stumpf @ 2012-07-12 13:30 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 11902

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

The overwrite with "bar" was caused by me: hitting return on rename and 
not typing "bar1".

I will try out the Edebug and get back to you later.  As to the sequence 
I usually do, you are very close. I usually already have the dired 
buffer open from before. It is:

C-x b Bernie
down arrow to someFile
R newName RET  (in minibuffer after "Rename someFile to: ~/"  )

-Bernie

Eli Zaretskii wrote:

>>Date: Thu, 12 Jul 2012 07:54:07 -0400
>>From: Bernard Stumpf <bernard.stumpf@verizon.net>
>>CC:  11902@debbugs.gnu.org
>>
>>I have not noticed any sensitivity to the characters in "newname". I 
>>just created a file named "foo" and did an R to "foo1" - the line 
>>disappeared.
>>    
>>
>
>OK.
>
>  
>
>>I did the same with file "bar" to "bar1". Here's output in *Messages*
>>...
>>(New file)
>>Saving file c:/Users/bernie/bar...
>>Wrote c:/Users/bernie/bar
>>Overwrite `c:/Users/bernie/bar'? [Type yn!q or C-h]  [5 times]
>>    
>>
>
>Any idea what that "Overwrite" message was about?
>
>  
>
>>As to using Edebug: I don't know Edebug.  Is there a way to set 
>>breakpoints inside emacs from emacs?
>>    
>>
>
>Edebug _is_ used from inside Emacs.  For example, to step through
>dired-do-redisplay and dired-update-file-line, you do this:
>
>  emacs -Q
>  M-x load-library dired-aux.el RET
>  C-x d some/directory RET
>  C-x C-f path/to/dired-aux.el RET
>  go to the function dired-do-redisplay
>  with cursor inside dired-do-redisplay's body, type:
>    M-x edebug-defun RET
>
>This instruments dired-do-redisplay, such that when it is called, the
>debugger kicks in automatically.  Think if this as a kind of a
>breakpoint you set on the function.
>
>Now, go to the Dired buffer to the line of the file you want to rename
>and press "R".  Emacs will pop up a window with the source of
>dired-do-redisplay, with a small arrow at the left showing the current
>line.  Typing SPC repeatedly will step through the code one Lisp form
>at a time, and will also show in the echo area the result of
>evaluating each form, so you can track what Emacs does and why.  To
>step into dired-update-file-line, type 'i' when you get just before
>the form that calls that function; then step through
>dired-update-file-line by repeatedly typing SPC again.
>
>Easy enough, isn't it?
>
>>From what you describe, I'd expect that dired-update-file-line deletes
>the line of the file being renamed, but then doesn't add the line for
>the new file, for some reason.  The addition is done by
>dired-add-entry, which dired-update-file-line calls; you can step into
>it by typing 'i' again.
>
>The information you obtain by stepping through these functions will
>probably get us much closer to resolving the problem, if not point out
>the problem right away.
>
>And just for the record: the way to reproduce the problem on that
>machine is just the following sequence, and nothing else, right?
>
>  emacs -Q
>  C-x d RET
>  go to some file
>  type R foo RET
>
>There's nothing else you do except the above sequence, correct?
>
>Thanks.
>

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

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

* bug#11902: Emacs 23.2: dired rename file and file is hidden - Windows 7
  2012-07-12 13:30               ` Bernard Stumpf
@ 2019-10-31  0:53                 ` Stefan Kangas
  2019-12-05 11:07                   ` Stefan Kangas
  0 siblings, 1 reply; 10+ messages in thread
From: Stefan Kangas @ 2019-10-31  0:53 UTC (permalink / raw)
  To: Bernard Stumpf; +Cc: 11902

Bernard Stumpf <bernard.stumpf@verizon.net> writes:

> The overwrite with "bar" was caused by me: hitting return on rename and not typing "bar1".
>
> I will try out the Edebug and get back to you later.

That was 7 years ago.  Are you still seeing this?

If yes, did you ever get around to trying this in edebug?  It seems like
we would need the information gained by doing that in order to make any
progress here.

Best regards,
Stefan Kangas





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

* bug#11902: Emacs 23.2: dired rename file and file is hidden - Windows 7
  2019-10-31  0:53                 ` Stefan Kangas
@ 2019-12-05 11:07                   ` Stefan Kangas
  0 siblings, 0 replies; 10+ messages in thread
From: Stefan Kangas @ 2019-12-05 11:07 UTC (permalink / raw)
  To: Bernard Stumpf; +Cc: 11902-done

Stefan Kangas <stefan@marxist.se> writes:

> Bernard Stumpf <bernard.stumpf@verizon.net> writes:
>
>> The overwrite with "bar" was caused by me: hitting return on rename and not typing "bar1".
>>
>> I will try out the Edebug and get back to you later.
>
> That was 7 years ago.  Are you still seeing this?
>
> If yes, did you ever get around to trying this in edebug?  It seems like
> we would need the information gained by doing that in order to make any
> progress here.

More information was requested, but none was given within 5 weeks, so
I'm closing this bug.  If this is still an issue, please reply to this
email (use "Reply to all" in your email client) and we can reopen the
bug report.

Best regards,
Stefan Kangas





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

end of thread, other threads:[~2019-12-05 11:07 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-07-10 17:43 bug#11902: Emacs 23.2: dired rename file and file is hidden - Windows 7 Bernard Stumpf
2012-07-11 16:02 ` Eli Zaretskii
     [not found]   ` <4FFDB03B.5060906@verizon.net>
2012-07-11 17:46     ` Eli Zaretskii
2012-07-12  0:05       ` Bernard Stumpf
2012-07-12  5:15         ` Eli Zaretskii
2012-07-12 11:54           ` Bernard Stumpf
2012-07-12 12:47             ` Eli Zaretskii
2012-07-12 13:30               ` Bernard Stumpf
2019-10-31  0:53                 ` Stefan Kangas
2019-12-05 11:07                   ` 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).