git-blame.el won't run
Hi,
I was happy to see that latest git's git included an emacs mode for git-blame.
Sadly, when trying it, I just have this displayed into *Messages* buffer:
Setting up indent for shell type bash setting up indent stuff Indentation variable are now local. Indentation setup for shell type bash
let: Process git-blame not running
If I launch git-blame manually onto the file from command line, it works.
It is on a emacs 22 (aka CVS version).
Xavier
Really, no one knows ?
Xavier
Quoted 5 lines · Xavier Maillard
Hi,
I was happy to see that latest git's git included an emacs mode for git-blame.
Quoted 8 lines
Sadly, when trying it, I just have this displayed into *Messages* buffer:
Setting up indent for shell type bash setting up indent stuff Indentation variable are now local. Indentation setup for shell type bash
let: Process git-blame not running
Can you please set debug-on-error to t and show me the backtrace you get?
And does M-! git-blame work in your emacs?
Signature · 1 line
David Kågedal
Hi,
Quoted 1 line
Can you please set debug-on-error to t and show me the backtrace you get?
Nothing happens. I have to C-g after having waited for a few seconds.
Quoted 1 line
And does M-! git-blame work in your emacs?
No it is not. It shows a help message (usage message).
Xavier
Quoted 3 lines · Xavier Maillard
Quoted 1 line
And does M-! git-blame work in your emacs?
No it is not. It shows a help message (usage message).
Do you use git new enough to have --incremental support for git-blame?
Signature · 3 lines
Jakub Narebski Warsaw, Poland ShadeHawk on #git
Quoted 6 lines · Xavier Maillard
Hi,
Quoted 1 line
Can you please set debug-on-error to t and show me the backtrace you get?
Nothing happens. I have to C-g after having waited for a few seconds.
I'm not sure my instructions were very clear. Did you try M-x git-blame-mode after enabling debug-on-error?
Quoted 3 lines
Quoted 1 line
And does M-! git-blame work in your emacs?
No it is not. It shows a help message (usage message).
But if the help message is for git-blame, it did work. I wanted to check that you could run git-blame from your emacs, and if it printed a usage message, it did run. If you want it to produce some real output, you have to give it a file name as well.
Signature · 1 line
David Kågedal
Hi,
Quoted 7 lines
Quoted 4 lines
Quoted 1 line
Can you please set debug-on-error to t and show me the backtrace you get?
Nothing happens. I have to C-g after having waited for a few seconds.
I'm not sure my instructions were very clear. Did you try M-x git-blame-mode after enabling debug-on-error?
I did it. And I had to kill (C-g) after having waited for several long seconds.
Xavier
Quoted 4 lines · Xavier Maillard
Hi,
Quoted 2 lines
Quoted 2 lines
Quoted 1 line
Can you please set debug-on-error to t and show me the backtrace you get?
Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
Nothing happens. I have to C-g after having waited for a few seconds.
I'm not sure my instructions were very clear. Did you try M-x git-blame-mode after enabling debug-on-error?
I did it. And I had to kill (C-g) after having waited for several long seconds.
OK, then set debug-on-quit to t and do it again, and send me the backtrace you get when you press C-g.
Signature · 1 line
David Kågedal
Hi,
This is the backtrace after C-g (after a few minutes):
Debugger entered--Lisp error: (quit)
process-send-region(#<process git-blame> 1 28910)
(let ((display-buf ...) (blame-buf ...) (args ...)) (if startline (setq args ...)) (setq args (append args ...)) (setq git-blame-proc (apply ... "git-blame" blame-buf "git" "blame" args)) (with-current-buffer blame-buf (erase-buffer) (make-local-variable ...) (make-local-variable ...) (setq git-blame-file display-buf) (setq git-blame-current nil)) (set-process-filter git-blame-proc (quote git-blame-filter)) (set-process-sentinel git-blame-proc (quote git-blame-sentinel)) (process-send-region git-blame-proc (point-min) (point-max)) (process-send-eof git-blame-proc)) (if git-blame-proc (message "Already running git blame") (let (... ... ...) (if startline ...) (setq args ...) (setq git-blame-proc ...) (with-current-buffer blame-buf ... ... ... ... ...) (set-process-filter git-blame-proc ...) (set-process-sentinel git-blame-proc ...) (process-send-region git-blame-proc ... ...) (process-send-eof git-blame-proc)))
git-blame-run()
(progn (let (...) (if ... ... ...)) (setq git-blame-cache (make-hash-table :test ...)) (git-blame-run))
(if git-blame-mode (progn (let ... ...) (setq git-blame-cache ...) (git-blame-run)) (cancel-timer git-blame-idle-timer))
git-blame-mode(nil)
call-interactively(git-blame-mode)
execute-extended-command(nil)
call-interactively(execute-extended-command)
Regards,
Xavier
Quoted 5 lines · Xavier Maillard
Hi,
This is the backtrace after C-g (after a few minutes):
Quoted 11 lines
Debugger entered--Lisp error: (quit)
process-send-region(#<process git-blame> 1 28910)
(let ((display-buf ...) (blame-buf ...) (args ...)) (if startline (setq args ...)) (setq args (append args ...)) (setq git-blame-proc (apply ... "git-blame" blame-buf "git" "blame" args)) (with-current-buffer blame-buf (erase-buffer) (make-local-variable ...) (make-local-variable ...) (setq git-blame-file display-buf) (setq git-blame-current nil)) (set-process-filter git-blame-proc (quote git-blame-filter)) (set-process-sentinel git-blame-proc (quote git-blame-sentinel)) (process-send-region git-blame-proc (point-min) (point-max)) (process-send-eof git-blame-proc)) (if git-blame-proc (message "Already running git blame") (let (... ... ...) (if startline ...) (setq args ...) (setq git-blame-proc ...) (with-current-buffer blame-buf ... ... ... ... ...) (set-process-filter git-blame-proc ...) (set-process-sentinel git-blame-proc ...) (process-send-region git-blame-proc ... ...) (process-send-eof git-blame-proc)))
git-blame-run()
(progn (let (...) (if ... ... ...)) (setq git-blame-cache (make-hash-table :test ...)) (git-blame-run))
(if git-blame-mode (progn (let ... ...) (setq git-blame-cache ...) (git-blame-run)) (cancel-timer git-blame-idle-timer))
git-blame-mode(nil)
call-interactively(git-blame-mode)
execute-extended-command(nil)
call-interactively(execute-extended-command)
If you switch to the buffer called " git blame for <filename>" (notice the leading space, you will probably see a usage/error message from git.
Maybe your git blame doesn't like the --incremental flag or the --contents flag. But the problem is that I'm not sure how to make emacs not hang.
process-send-region blocks when sending the file contents, since git isn't reading it. But git finishes, so emacs should be able to detect that there is no process that can read anything anymore.
Signature · 1 line
David Kågedal
Hi,
Quoted 3 lines
If you switch to the buffer called " git blame for <filename>" (notice the leading space, you will probably see a usage/error message from git.
Seen it.
Quoted 3 lines
Maybe your git blame doesn't like the --incremental flag or the --contents flag. But the problem is that I'm not sure how to make emacs not hang.
Ok. I fixed this by upgrading to latest stable release of Git (according to website it is 1.5.0).
It now works as expected !
Thank you very much for your time and patience.
Xavier