terminal prompts disabled when submodules: true
See original GitHub issueHaving issue with submodules. I have a private repo which has other private repos as submodules. Tried with the workflow below, but keeps showing following error message for all my submodules:
/usr/bin/git -c protocol.version=2 submodule update --init --force --depth=1 --recursive
Cloning into '<MY_SUBMODULE_REPO>'...
Error: fatal: could not read Username for 'https://github.com/': terminal prompts disabled
However, since removing line with submodules from workflow worked (without cloning submodules), I assume that auth process is broken.
My workflow:
name: Testing
on:
push:
branches: [ test-action ]
jobs:
steps:
runs-on: self-hosted
steps:
- uses: actions/checkout@v2
with:
submodules: true
ssh-key: ${{ secrets.SSH_KEY }}
What I tried:
- Checked secrets
- Tried with token instead of ssh-key (including checking scopes of PAT)
- Change self-hosted to ubuntu-latest
All didn’t work.
Issue Analytics
- State:
- Created a year ago
- Reactions:3
- Comments:6
Top Results From Across the Web
No results found
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
In our organization this error was caused by the fact that the Personal Access Token (PAT) had expired.
To be able to checkout the submodule, a PAT is required - this is passed in the workflow as an environment value that is retrieved from the repo “secrets”:
The annoying thing is that the PAT needs to be linked to a specific account (so not the Github organization). So I discover that my “personal” PAT was outdated.
Solution was simple:
Done!
در تاریخ چهارشنبه ۲۳ مارس ۲۰۲۲، ۱۲:۲۲ piuy11 @.***> نوشت: