chrisbra / Recover.vim

A Plugin to show a diff, whenever recovering a buffer
http://www.vim.org/scripts/script.php?script_id=3068
247 stars 25 forks source link

Error detected while processing function <SNR>37_CheckSwapFileExists: #2

Closed rahulkmr closed 12 years ago

rahulkmr commented 12 years ago

Hi,

When swap file exists, I am shown this error.

Error detected while processing function <SNR>37_CheckSwapFileExists:
line    8:
E325: ATTENTION

Line 37 in CheckSwapFileExists is simply obtaining the name of the swapfile.

redir => a | sil swapname |redir end

I am not sure what's wrong and what info do I need to provide to nail down the issue.

chrisbra commented 12 years ago

On Fri, March 16, 2012 12:08, Rahul Kumar wrote:

Hi,

When swap file exists, I am shown this error.

Error detected while processing function <SNR>37_CheckSwapFileExists:
line    8:
E325: ATTENTION

Line 37 in CheckSwapFileExists is simply obtaining the name of the swapfile.

redir => a | sil swapname |redir end

I am not sure what's wrong and what info do I need to provide to nail down the issue.

Can you reproduce this issue?

regards, Christian

chrisbra commented 12 years ago

On Fri, March 16, 2012 12:08, Rahul Kumar wrote:

Hi,

When swap file exists, I am shown this error.

Error detected while processing function <SNR>37_CheckSwapFileExists:
line    8:
E325: ATTENTION

Line 37 in CheckSwapFileExists is simply obtaining the name of the swapfile.

redir => a | sil swapname |redir end

I am not sure what's wrong and what info do I need to provide to nail down the issue.

I think latest head fixes the issue.

regards, Christian

rahulkmr commented 12 years ago

I did a git pull and now I am getting a different error:

Swap File found: Diff buffer? 
"memg_epoll.py" 73L, 2102C
No differences, deleting old swap file
Error detected while processing function <SNR>50_KeyMap_Invoke..59..58..<SNR>50_activateFileNode..83..102..145..146..163:
line    1:
E305: No swap file found for memg_epoll.py
No differences, deleting old swap file
Press ENTER or type command to continue
chrisbra commented 12 years ago

On Wed, March 21, 2012 11:03, Rahul Kumar wrote:

I did a git pull and now I am getting a different error:

Swap File found: Diff buffer?
"memg_epoll.py" 73L, 2102C
No differences, deleting old swap file
Error detected while processing function
50_KeyMap_Invoke..59..58..50_activateFileNode..83..102..145..146..163: line 1: E305: No swap file found for memg_epoll.py No differences, deleting old swap file Press ENTER or type command to continue

That looks like an error in a different plugin. Check the output of :scriptnames for the number 50. That tells you, what script and function is running.

regards, Christian

rahulkmr commented 12 years ago

Thanks for the the help. It looks like NERDTree and recover aren't playing well together.

  1. I open a file, make changes and kill the window without saving it.
  2. I open vim, open nerdtree, and open the same file.
Swap File found: Diff buffer?
"memg_epoll.py" 73L, 2102C
No differences, deleting old swap file
Error detected while processing function
50_KeyMap_Invoke..59..58..50_activateFileNode..83..102..145..146..163: line 1: E305: No swap file found for memg_epoll.py No differences, deleting old swap file Press ENTER or type command to continue

It deletes the swap file, even though the swap file is different from on-disk copy, and it throws me a NERDTree error.

If I directly open the file in vim, it doesn't throw me any errors, and correctly shows the diff.

chrisbra commented 12 years ago

On Wed, March 21, 2012 13:29, Rahul Kumar wrote:

Thanks for the the help. It looks like NERDTree and recover aren't playing well together.

1 I open a file, make changes and kill the window without saving it.

  1. I open vim, open nerdtree, and open the same file.
Swap File found: Diff buffer?
"memg_epoll.py" 73L, 2102C
No differences, deleting old swap file
Error detected while processing function
50_KeyMap_Invoke..59..58..50_activateFileNode..83..102..145..146..163: line 1: E305: No swap file found for memg_epoll.py No differences, deleting old swap file Press ENTER or type command to continue

It deletes the swap file, even though the swap file is different from on-disk copy, and it throws me a NERDTree error.

Hm, I'll need to look into it later.

If I directly open the file in vim, it doesn't throw me any errors, and correctly shows the diff.

regards, Christian

chrisbra commented 12 years ago

see if current head works better for you.

rahulkmr commented 12 years ago

The current head solves the swapfile recovery issue, but it now throws me an error while finishing recovery.

Error detected while processing function recover#RecoverFinish:
line    5:
E121: Undefined variable: b:swapname
E116: Invalid arguments for function delete

On Sat, Mar 24, 2012 at 1:21 AM, chrisbra < reply@reply.github.com

wrote:

see if current head works better for you.


Reply to this email directly or view it on GitHub: https://github.com/chrisbra/Recover.vim/issues/2#issuecomment-4666668

chrisbra commented 12 years ago

Hi Rahul!

On Sa, 24 Mär 2012, Rahul Kumar wrote:

The current head solves the swapfile recovery issue, but it now throws me an error while finishing recovery.

Error detected while processing function recover#RecoverFinish:
line    5:
E121: Undefined variable: b:swapname
E116: Invalid arguments for function delete

On Sat, Mar 24, 2012 at 1:21 AM, chrisbra < reply@reply.github.com

wrote:

see if current head works better for you.

Please try current head

regards,

Christian

Treffen sich zwei Yetis im Himalaja. Sagt der eine: "Du, ich hab' gestern Reinhold Messner gesehen." Sagt der andere: "Was? Gibt's den wirklich?"

rahulkmr commented 12 years ago

Hey Christian,

Thanks a ton for the help. It works perfectly now.

chrisbra commented 12 years ago

ok, closing now