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

repository not found #254

Closed
DgRosa opened this issue May 22, 2020 · 209 comments
Closed

repository not found #254

DgRosa opened this issue May 22, 2020 · 209 comments

Comments

@DgRosa
Copy link

DgRosa commented May 22, 2020

[edited by @ericsciple] Sorry for the disruption. There is an active incident right now that is causing the GITHUB_TOKEN to not have permission to checkout private repos.

Everything was working fine until all of the sudden this error started to popup and I have no idea why.
Can it be a GitHub service issue or maybe a recent release that introduced a bug.
It's a private repository I don't know if that can help debug the issue.

Workflow stack

/usr/bin/git -c protocol.version=2 fetch --no-tags --prune --progress --no-recurse-submodules --depth=1 origin +7f692a64151c6ae3be4518df16d88b891eb76c1b:refs/remotes/origin/master
  remote: Repository not found.
  ##[error]fatal: repository 'https://github.com/DgRosa/likacrm/' not found
  The process '/usr/bin/git' failed with exit code 128
@DgRosa DgRosa changed the title repository 'https://github.com/DgRosa/likacrm/' not found repository not found May 22, 2020
@ryanmiriyagalla
Copy link

ryanmiriyagalla commented May 22, 2020

+1 on this. Github actions suddenly started giving this error.
"Investigating - We are investigating an increase in errors on GitHub.com."
I think this is due an error in github. Check https://www.githubstatus.com/

@bigfootjon
Copy link

bigfootjon commented May 22, 2020

I think it's something to do with private repos? I just reran some public repo actions and they worked correctly, but my private repos are failing every time.

@dcarlstedt
Copy link

dcarlstedt commented May 22, 2020

I am also having this exact same issue. It started appearing somewhere in the last hour to our private repos.

@sergeh
Copy link

sergeh commented May 22, 2020

+1 also just started to happen on our private repos

@mcbanderson
Copy link

mcbanderson commented May 22, 2020

Happening on my private repos as well, for both v1 and v2.

Edit: Looks like GitHub is experiencing some service degradation, so this could be a GitHub issue and not an issue with this action.

@faizanakram99
Copy link

Same, was about to open an issue.

Didn't know whether it is related to this repository or to GitHub

@brettpalmberg
Copy link

+1 . Same issue with GitHub Actions and private repos.

@Albinzr
Copy link

Albinzr commented May 22, 2020

Same issue all the build process is stuck for me

@dianhsu
Copy link

dianhsu commented May 22, 2020

Oops....

@patrickk
Copy link

+1, same here. Repo exists.

@Albinzr
Copy link

Albinzr commented May 22, 2020

Are the any alternatives for checkout that can be used as fallback

@Andrew-Kulpa
Copy link

I'm experiencing this issue too! 👍

@belalessandro
Copy link

Same for me

@pinkstrings
Copy link

Anyone know if this is an issue with Github itself, or specific to the code in this action?

@ilgooz
Copy link

ilgooz commented May 22, 2020

Anyone know if this is an issue with Github itself, or specific to the code in this action?

Probably due to an issue with Github APIs. We are using a fixed version of checkout which is @v2 and still experiencing this issue.

@ericsciple can you please report this issue to the team?


I got more news, the status page is yellow, there seems to be an incident ATM. See: https://www.githubstatus.com/

@cfbao
Copy link

cfbao commented May 22, 2020

Anyone know if this is an issue with Github itself, or specific to the code in this action?

Pretty sure it has nothing to do with the checkout action.
The latest code change is yesterday, but it was running fine this morning.

@veich
Copy link

veich commented May 22, 2020

@github Team - that's why you don't do deployments on Friday 😁

EDIT: November 27th 2020 - repeat error & they did it again on Friday 🤦 😂

@handhead-dev
Copy link

+1

@ericsciple
Copy link
Contributor

@ilgooz there is an ongoing investigation - it's known. Not an issue w/ this repo as you mentioned.

@ivandimitrovSC
Copy link

ivandimitrovSC commented May 22, 2020

Thanks for this issue! I literally merged our first workflow 90 minutes ago and have been debugging the broken CI ever since. Knowing it's service degradation is of some relief.

@AnthonyKinson
Copy link

+1 same thing just started happening in our org private repos

@PrinsFrank
Copy link

Only affects our private repos, public ones still work fine.

@weihao
Copy link

weihao commented May 22, 2020

Adding logs

  remote: Repository not found.
  ##[error]fatal: repository 'https://github.com/user/repository/' not found
  The process '/usr/bin/git' failed with exit code 128

@finnkauski
Copy link

Same here. Issue with private repo deployment. Spent like and hour figuring it out. Feel like such an idiot not having a look here first!

@batok
Copy link

batok commented May 22, 2020

When actions/checkout runs fetches the master version of this repo? I mean github tries to fetch the most recent version?

@maurigvs
Copy link

Just ran into this issue today with a company github repo. Still have not find a solution.

@lilac
Copy link

lilac commented Feb 23, 2024

Me too. It used to work well, but started throwing this error from yesterday.

The workaround is add the contents permission, if it's not there.

permissions:
  contents: read

@danieldelarosaagility
Copy link

danieldelarosaagility commented Feb 23, 2024

permissions:
  contents: read

Updating the permissions as described above does not work for a private repo.

I'm having this issue with both actions/checkout@v3 and actions/checkout@v4

@maurigvs
Copy link

maurigvs commented Feb 26, 2024

I solved my problem, passing the secrets from the called workflow to the called workflow.

My context is enterprise internal repositories.

@mialdi98
Copy link

Resolved my issue

permissions:
  contents: read
  packages: write

and here where to use it:

name: GitHub Actions
run-name: ${{ github.actor }} is testing out GitHub Actions 🚀
permissions:
  actions: write       # Necessary to cancel workflow executions
  checks: write        # Necessary to write reports
  pull-requests: write # Necessary to comment on PRs
  contents: read
  packages: write
on: [pull_request]
jobs:
  setup_dependencies:
    timeout-minutes: 120
    runs-on: ubuntu-22.04
    steps:
      - name: Checkout repo
        uses: actions/checkout@v4
        with:
          token: ${{ secrets.GITHUB_TOKEN }}

@jmcconathy
Copy link

These workaround are not working for me either.

Both repositories are in the same organization. And the second repo is configured to be available to workflows in the org (I have also tried setting it to be available to workflows enterprise wide but to no difference in outcome).
My workflow still says the repo was not found.
If i make the repo public it works, and if i set an organizational token (which i cant make last longer than 90 days), then it works fine.

@lvl99
Copy link

lvl99 commented Mar 13, 2024

I'm working in a private repo which is part of an org with SSO enabled. I'm using an action which sets PR comments so had permissions configured:

permissions:
  pull-requests: write

I got the "repository not found" error, to which this thread helped me by suggesting I add the contents: read line:

permissions:
  contents: read
  pull-requests: write

Seemed to work! Thanks all.

@markanthonyuy
Copy link

I wish github can provide a better error message regarding this issue. It's really the permissions that's causing this

@ampcpmgp
Copy link

This occurred in the public repository. I tried the workaround and still got the error.

I wrote the following clone command to work around it.

git clone --depth 1 --branch ${{ github.ref_name }} --single-branch https://github.com/ampcpmgp/elemental-sea.git .

@dralshehri
Copy link

dralshehri commented Apr 13, 2024

I found that for jobs with any permissions set, I need to set other permissions, too; otherwise, they will default to none.

To fix the checkout issue, I added contents: read to permissions, which works for me.

For reference:

If you specify the access for any of these scopes, all of those that are not specified are set to none.

👆🏼 from Defining access for the GITHUB_TOKEN scopes

@vgundavarapu
Copy link

I am still getting this issue and mine is a private repo from which I am trying to pull and I tried the permissions fix which was suggested by others and still seeing the issue

@pritisolanki
Copy link

It is still a issue

@CharMinder
Copy link

Ran into this issue today. Generate a personal access token with read permission for both the repository you are trying to install as a package as well as the repository the action is for. In your deploy.yml explicitly set the token like so. Also in the repository you are trying to install, go to settings -> actions -> general -> access -> click the radio option that says "Accessible from repositories in the 'abc' organization" and save

Screenshot 2024-09-25 at 5 19 52 PM

@ambersun1234
Copy link

I ran into the same issue using GitHub App authentication for my organization
any new updates?

@MiltiadisKoutsokeras
Copy link

After so many months of having this issue is some repositories I start to believe that the problem has a possibility of being caused by back-end configuration that is not controlled by the end-user. No matter what I applied from the suggestions in this thread does not fix the issue and newly created repositories with the exactly the same CI/CD setup do not reproduce the issue.

@iustin94
Copy link

iustin94 commented Oct 2, 2024

Seems to still be an issue

@iamwilsoncardoso
Copy link

Same.

@drone1
Copy link

drone1 commented Oct 4, 2024

I ended up making a dedicated GitHub user with specific permissions for doing work in the context of Actions, and it resolved this issue for me. I read somewhere that this was the recommended pattern but now I don't see it in the readme.

@Tony-1992
Copy link

I all of a sudden ran into this issue today, when attempting to apply this action to an company internal github repo.

Changing

permissions: actions: read pages: write id-token: write

to

permissions: actions: read contents: read pages: write id-token: write

seems to have fixed it for me at least.

(using actions/checkout@v3)

Just had this issue when trying to deploy a private repo and this comment helped me, using v4 actions.

I've wasted hours and trawled through 4 years worth of comments and attempted solutions... the error messages need to be more descriptive for this and not just "Repo Not Found".

@icheered
Copy link

I'm still encountering the same issue: "Repository not found". The situation is an action that should sync a private repository of one organization with a private repo of another organization. Using the CLI locally the commands work fine, but in github actions fails. Fetching permissions (https://api.github.com/repos/$TARGET_REPO) works fine, and setting the remote also works, but it fails on fetching/pushing.

Again, locally this works fine...

@gcb
Copy link

gcb commented Oct 31, 2024

also seeing this on newly created repo. Nothing fancy like the last comment with cross-organization repos.

Current runner version: '2.320.0'
Operating System
  Ubuntu
  22.04.5
  LTS
Runner Image
  Image: ubuntu-22.04
  Version: 20241015.1.0
  Included Software: https://github.com/actions/runner-images/blob/ubuntu22/20241015.1/images/ubuntu/Ubuntu2204-Readme.md
  Image Release: https://github.com/actions/runner-images/releases/tag/ubuntu22%2F20241015.1
Runner Image Provisioner
  2.0.384.1
GITHUB_TOKEN Permissions
  Contents: read
  Metadata: read
  Packages: read
Secret source: Actions
Prepare workflow directory
Prepare all required actions
Getting action download info
Error: Unable to resolve action https:/github.com, repository not found

edit: turn out this is the top result for a really bad error string which removes the only useful information.

This means github workflow/action failed to fetch some step dependency.

I had uses: [email protected] from an old file. But looking at that dependency on the 'marketplace' it now shows as actions-netlify@4cbaf4c08f1a7bfa537d6113472ef4424e4eb654. After fixing the reference it works.

It can also cause problems as other compatible platforms (forgejo, gitlab, etc) which uses the github full url for those, but github itself won't accept it. So if your uses: start with https://github.com/ completely remove that part and leave only user/repo@version.

@ksparakis
Copy link

I ran into this issue when I added permissions to my job.

permission:
   deployments: write

To one of my jobs. I am under the assumption, jobs have a default set of permissions that when you add the Permissions field, it overwrites. So what you need to do is simply add the Permission for you Github action Job to read from your private repo. Double check all permissions and you should be good to go 💯

Here is a list of all Permissions I could find:

permissions:
  actions: read|write|none
  checks: read|write|none
  contents: read|write|none
  deployments: read|write|none
  id-token: read|write|none
  issues: read|write|none
  discussions: read|write|none
  packages: read|write|none
  pages: read|write|none
  pull-requests: read|write|none
  repository-projects: read|write|none
  security-events: read|write|none
  statuses: read|write|none

Here is a nice article explaining permissions in github actions:
https://dev.to/pwd9000/fgjgghjgh-19ka

Hope this helps 🫡

@JeBear76
Copy link

JeBear76 commented Nov 5, 2024

contents: read

Thank you!

@medace-ahmed
Copy link

Resolved my issue

permissions:
  contents: read
  packages: write

and here where to use it:

name: GitHub Actions
run-name: ${{ github.actor }} is testing out GitHub Actions 🚀
permissions:
  actions: write       # Necessary to cancel workflow executions
  checks: write        # Necessary to write reports
  pull-requests: write # Necessary to comment on PRs
  contents: read
  packages: write
on: [pull_request]
jobs:
  setup_dependencies:
    timeout-minutes: 120
    runs-on: ubuntu-22.04
    steps:
      - name: Checkout repo
        uses: actions/checkout@v4
        with:
          token: ${{ secrets.GITHUB_TOKEN }}

This worked for me!! Thanks much!

@Poornima030596
Copy link

in my case both the main repo and sub module repo are in the same organization but still its failing in github actions and works fine in local

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests