Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error in process sentinel: fatal: invalid object name 'fatal' #151

Closed
bcc32 opened this issue Aug 19, 2023 · 9 comments
Closed

error in process sentinel: fatal: invalid object name 'fatal' #151

bcc32 opened this issue Aug 19, 2023 · 9 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@bcc32
Copy link
Contributor

bcc32 commented Aug 19, 2023

After the recent update, I see the following error messages appear after magit-todos runs (before its output is inserted into the magit-status buffer):

error in process sentinel: magit-todos--async-when-done: magit-todos--async-when-done: process "magit-todos--scan-with-git-diff" failed with exit code 128.  Output:"fatal: invalid object name 'fatal'.
"
error in process sentinel: magit-todos--async-when-done: process "magit-todos--scan-with-git-diff" failed with exit code 128.  Output:"fatal: invalid object name 'fatal'.
"
Error in post-command-hook (magit-section-post-command-hook): (args-out-of-range 99145 99145)
@alphapapa alphapapa self-assigned this Aug 19, 2023
@alphapapa alphapapa added the bug Something isn't working label Aug 19, 2023
@alphapapa alphapapa added this to the 1.7 milestone Aug 19, 2023
@alphapapa
Copy link
Owner

Thanks, I'll fix this soon.

@alphapapa
Copy link
Owner

@bcc32 That seems to fix it. Please let me know if it does for you.

@bcc32
Copy link
Contributor Author

bcc32 commented Aug 19, 2023

Unfortunately I'm getting the same error.

In the repo where I'm getting the error, I evaluated:

(-> "git merge-base HEAD "
  (concat magit-todos-branch-list-merge-base-ref)
  shell-command-to-string
  string-trim)

which returned:

"fatal: Not a valid object name master"

This is a repo whose default branch is called main (which is git's new default).

I tried in a repo whose default branch is still called master, and did not see the error.

Should magit-todos perhaps automatically determine the default branch name by asking git? (init.defaultBranch config item)

@alphapapa
Copy link
Owner

What happens if you set the option magit-todos-branch-list-merge-base-ref to main?

@alphapapa alphapapa reopened this Aug 20, 2023
@bcc32
Copy link
Contributor Author

bcc32 commented Aug 21, 2023

It works fine when that variable is set to main. Also, it stops raising an error in repos whose default branch is called master, but I suspect that's because behavior for "master" is hardcoded in magit-todos--insert-todos.

@seagle0128
Copy link

I still encountered this issue with magit-todos-20230819.732.

@rweir
Copy link

rweir commented Aug 25, 2023

I'm also seeing this on 20230819.732, though the workaround in #151 (comment) does work for repos where the main branch is 'main' or 'master'.

@bcc32
Copy link
Contributor Author

bcc32 commented Aug 26, 2023

The new update seems to work correctly for me, without customizing magit-todos-branch-list-merge-base-ref. Thanks!

@alphapapa
Copy link
Owner

Thanks, Aaron.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants