GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — difficult error when fetching remote refs · gitpython-developers/GitPython · Discussion #1983

difficult error when fetching remote refs #1983

Unanswered
mjgaughan asked this question in Q&A
difficult error when fetching remote refs #1983
@mjgaughan mjgaughan
Dec 10, 2024 · 1 comments · 1 reply
Return to top
Discussion options
  • Uh oh!

    There was an error while loading. Please reload this page.

mjgaughan
Dec 10, 2024

Hello!

I am running into an error when I try to fetch some refs from the remote of my repository. I have spent some time in the GitPython docs but am still unable to work my head around where I could be going wrong, thus I am opening the ticket.

I'm running into issues with the line below, where repo is a git.Repo instance.
repo.remote().fetch('refs/pull/*/merge:refs/pull/*/merge')
I have pasted the partial traceback below:

 File "collating_prs.py", line 12, in get_prs
    results = repo.remote().fetch('refs/pull/*/merge:refs/pull/*/merge')
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "lib/python3.11/site-packages/git/remote.py", line 1069, in fetch
    res = self._get_fetch_info_from_stderr(proc, progress, kill_after_timeout=kill_after_timeout)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/lib/python3.11/site-packages/git/remote.py", line 895, in _get_fetch_info_from_stderr
    proc.wait(stderr=stderr_text)
  File "/lib/python3.11/site-packages/git/cmd.py", line 834, in wait
    raise GitCommandError(remove_password_if_present(self.args), status, errstr)
git.exc.GitCommandError: Cmd('git') failed due to: exit code(1)
  cmdline: git fetch -v -- origin refs/pull/*/merge:refs/pull/*/merge

In a bash terminal, the command git fetch -v -- origin refs/pull/*/merge:refs/pull/*/merge works and returns the refs that I am trying to fetch.

I'm not quire sure where to start looking at this and would appreciate any guidance. Thank you for your help!

You must be logged in to vote
All reactions

Replies: 1 comment · 1 reply

Comment options
  • Uh oh!

    There was an error while loading. Please reload this page.

Byron
Dec 10, 2024
Maintainer

I recommend to set GIT_PYTHON_TRACE=full to hopefully see more output.

The usual issue would be an authentication failure.

I hope that helps.

You must be logged in to vote
All reactions
1 reply
@mjgaughan
Comment options
  • Uh oh!

    There was an error while loading. Please reload this page.

mjgaughan Dec 10, 2024
Author

Yes! Thank you --- it seems to be an authentication failure.

All reactions
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
🙏
Q&A
Labels
None yet
2 participants
@mjgaughan @Byron
Converted from issue

This discussion was converted from issue #1982 on December 10, 2024 06:11.

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.