6
submitted 1 year ago* (last edited 1 year ago) by ggnoredo@lemm.ee to c/emacs@lemmy.ml

Hi,

I'm using the function below (found on somewhere else)

(defun my-magit-fetch-all-repositories ()
  "Run `magit-fetch-all' in all repositories returned by `magit-list-repos`."
  (interactive)
  (dolist (repo (magit-list-repos))
    (message "Fetching in %s..." repo)
    (let ((default-directory repo))
      (magit-fetch-all (magit-fetch-arguments)))
    (message "Fetching in %s...done" repo)))

This was working fine and successfully fetching from all of my repos. But recently it randomly generates an error on a random repo with the message of:

magit fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.

If I try to magit-fetch-all manually then it works and does not throw the error since I have correct rights and ssh key. If I re-run my-magit-fetch-all-repositories, it randomly generates same error on different repo or repos.

Have any idea on this?

you are viewing a single comment's thread
view the rest of the comments
[-] herbert@programming.dev 1 points 1 year ago

github? They recently reset their keys. You may need to update multiple "known hosts" as there can be multiple entries in your ~/.ssh/known_hosts file for them as there are multiple IPs they use and you won't consistently get the same ones, which could lead to the behavior you see.

[-] ggnoredo@lemm.ee 1 points 1 year ago

Self hosted gitea but I'm gonna check this. Ty

this post was submitted on 18 Jul 2023
6 points (100.0% liked)

Emacs

1978 readers
1 users here now

Our infinitely powerful editor.

founded 4 years ago
MODERATORS