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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Workflow always fails at the "Create New Branch" stage #43
Comments
Hi @nicoddemus, Thanks for reporting the issue.
This is the function that creates a new branch: github-actions-version-updater/src/run_git.py Lines 18 to 26 in 8a64997
|
Thanks for the quick response!
name: Update GitHub actions
on:
schedule:
# At 08:30 on Monday.
# https://crontab.guru
- cron: '30 8 * * 1'
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
token: ${{ secrets.WORKFLOW_SECRET }}
- name: Run GitHub Actions Version Updater
uses: saadmk11/github-actions-version-updater@v0.7.1
with:
token: ${{ secrets.WORKFLOW_SECRET }}
committer_username: 'Bruno Oliveira'
committer_email: 'nicoddemus@gmail.com'
commit_message: 'Update GitHub Actions to their latest versions'
pull_request_title: 'Pull Request Title'
update_version_with: 'release-tag'
release_types: "all" You will notice that there is no LFS configuration, that's my original attempt. I configured LFS with:
But this still gives the exact same error.
Yes, sorry for not making that clearer.
Here is the relevant part (can't share the full link because it is a private repo):
Yes I did browse the action code and found that function, thanks. The same could be accomplished with a single command btw: with gha_utils.group(
f"Create New Branch ({base_branch_name} -> {new_branch_name})"
):
run_subprocess_command(["git", "checkout", "-b", new_branch_name, base_branch_name]) Any specific reason why this is done currently with two commands? Not that I think it is related with my problem, just curious. 馃榿 Thanks! |
Did investigate a bit more, and indeed the problem might be GitLFS: Seems like this is a problem if Will try to remove the hook manually and see if it works. 馃憤 |
Indeed that was the problem, I fixed by adding an extra step that removed the hooks explicitly: - name: Remove LFS hook
# If the LFS related hooks are present, the GitHub Actions updater
# will fail because Git will complain about git-lfs not being
# on the $PATH, because indeed is not available in the action's container.
# https://github.com/saadmk11/github-actions-version-updater/issues/43
run: |
rm .git/hooks/post-checkout
rm .git/hooks/pre-push I think this can be solved in this repo in two ways:
I will open a PR with 2) as this might help others with the same problem right away. 馃憤 |
Opened #44. 馃憤 |
Hi!
First of all thanks for writing this action and making it publicly available. 馃憤
I'm trying to make it to work, however for me it always fails at the Create New Branch stage, and unfortunately I can't see the reason for that from the output:
Using version
0.7.1
.I did try to disable Git LFS (even though doesn't seem like that would be a problem), with the same results.
Any hints?
Thanks
The text was updated successfully, but these errors were encountered: