Permission denied when trying to checkout ticket using git trac

97 views
Skip to first unread message

Philip Meersman

unread,
Feb 15, 2021, 11:08:26 PM2/15/21
to sage-support
Hello,

I am using Sage 9.2 compiled from source on WSL (Ubuntu on Windows 10).

I'm trying to pull changes from an updated ticket remotely using git trac. I have configured git trac from the developer's guide "Collaborative Development with Git-Trac", following the steps there and also from the "Git-Trac Integration" README. I notice that my trac fetch URL looks different from that on the developer's guide. Things look good until I try to checkout the ticket when I receive a permission error. I notice it is a publickey error, but I have already added a public key to my trac account.


git remote versions
*****************************************

git remote -v

origin  git://trac.sagemath.org/sage.git (fetch)

origin  git://trac.sagemath.org/sage.git (push)

trac    g...@trac.sagemath.org:sage.git (fetch)

trac    g...@trac.sagemath.org:sage.git (push)



permission error when trying to checkout ticket

*******************************************

git trac checkout 18735

Loading ticket #18735...
Checking out Trac #18735 .....
Traceback (most recent call last):
  File "/home/philipblaine/.local/bin/git-trac", line 17, in <module>
    cmdline.launch()
  File "/home/philipblaine/.local/lib/python2.7/site-packages/git_trac/cmdline.py", line 239, in launch
    app.checkout(args.ticket_or_branch, args.branch_name)
  File "/home/philipblaine/.local/lib/python2.7/site-packages/git_trac/app.py", line 118, in checkout
    self._checkout_ticket(int(ticket_or_branch), branch_name)
  File "/home/philipblaine/.local/lib/python2.7/site-packages/git_trac/app.py", line 146, in _checkout_ticket
    self.repo.checkout_new_branch(ticket.branch, branch)
  File "/home/philipblaine/.local/lib/python2.7/site-packages/git_trac/git_repository.py", line 135, in checkout_new_branch
    self.git.fetch('trac', remote)
  File "/home/philipblaine/.local/lib/python2.7/site-packages/git_trac/git_interface.py", line 340, in meth
    return self.execute(git_cmd, *args, **kwds)
  File "/home/philipblaine/.local/lib/python2.7/site-packages/git_trac/git_interface.py", line 327, in execute
    popen_stderr=subprocess.PIPE)
  File "/home/philipblaine/.local/lib/python2.7/site-packages/git_trac/git_interface.py", line 262, in _run
    raise GitError(result)
git_trac.git_error.GitError: git returned with non-zero exit code (128) when executing "git fetch trac u/yzh/hybrid_backend"
    STDERR: g...@trac.sagemath.org: Permission denied (publickey).
    STDERR: fatal: Could not read from remote repository.
    STDERR:
    STDERR: Please make sure you have the correct access rights
    STDERR: and the repository exists.


Any information is greatly appreciated! Thanks.

Philip Meersman

Dima Pasechnik

unread,
Feb 16, 2021, 4:33:43 AM2/16/21
to sage-support
You can just ignore "git trac" extension and use plain git.
I think of "git trac" as more of the release manager tool than anything else.

Anyhow, it could be that a python2 you have installed in ~/. local causes
these issues.
I would have python3 installed in your WSL and just used it.



--
You received this message because you are subscribed to the Google Groups "sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sage-support...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sage-support/7227cfb7-7680-4a46-ad2e-05248321bf1dn%40googlegroups.com.

Dima Pasechnik

unread,
Feb 16, 2021, 6:42:56 AM2/16/21
to sage-support
On Tue, Feb 16, 2021 at 9:33 AM Dima Pasechnik <dim...@gmail.com> wrote:
>
> You can just ignore "git trac" extension and use plain git.
> I think of "git trac" as more of the release manager tool than anything else.

e.g. in this case you could have done
git fetch origin u/yzh/hybrid_backend

Philip Meersman

unread,
Feb 18, 2021, 1:20:15 AM2/18/21
to sage-s...@googlegroups.com
I believe I now have it sorted out by using plain git, thank you!

Reply all
Reply to author
Forward
0 new messages