[ISSUE]: unsupported extension name extensions.worktreeconfig
Prerequisites
- [X] I have written a descriptive issue title
- [X] I have searched issues to ensure it has not already been reported
GitVersion package
GitHub Actions
What are you seeing?
unsupported extension name extensions.worktreeconfig Looks like issue https://github.com/GitTools/actions/issues/1090 is suddenly back
What is expected?
No error
Steps to Reproduce
The error is suddenly back:
Run actions/checkout@v4 with: fetch-depth: 0 fetch-tags: true repository: / token: *** ssh-strict: true persist-credentials: true clean: true sparse-checkout-cone-mode: true show-progress: true lfs: false submodules: false set-safe-directory: true
/usr/bin/git version git version 2.34.1
Run gittools/actions/gitversion/setup@v1 with: versionSpec: 5.x preferLatestVersion: true includePrerelease: false ignoreFailedSources: false
Run gittools/actions/gitversion/execute@v1 with: disableShallowCloneCheck: true useConfigFile: false disableCache: false disableNormalization: false configFilePath: GitVersion.yml updateAssemblyInfo: false Resulting in:
INFO [04/22/24 15:49:41:90] Working directory: /home/ubuntu/_work// unsupported extension name extensions.worktreeconfig INFO [04/22/24 15:49:41:95] Done writing Error: Error: The process '/home/ubuntu/_work/_tool/GitVersion.Tool/5.12.0/x64/dotnet-gitversion' failed with exit code 1
Output log or link to your CI build (if appropriate).
No response
Same issue here - I had an actions workflow that worked fine today (22/04/2024) at 15:11 (GMT + 1), and then started failing with the same error - "unsupported extension name extensions.worktreeconfig" at 15:28 for no obvious reason.
The original error came from a custom workflow we've written that calls the dotnet-gitversion tool v5.10.3 (and not changed recently), but I can reproduce it with the latest version (v5.12.0) and with the gittools actions in a vanilla config:
steps:
- uses: actions/checkout@v4
with:
# needed for gitversion to work
fetch-depth: 0
- name: gitversion setup
uses: gittools/actions/gitversion/[email protected]
with:
versionSpec: 5.x
- name: gitversion execute
uses: gittools/actions/gitversion/[email protected]
The result is:
... snip ...
Command: git -C /opt/actions-runner/_work/devops-github-runners/devops-github-runners rev-parse --is-shallow-repository
... snip ...
unsupported extension name extensions.worktreeconfig
... snip ...
Error: Error: The process '/opt/actions-runner/_work/_tool/GitVersion.Tool/5.12.0/x64/dotnet-gitversion' failed with exit code 1
(full "debug" logs available if it's useful, but I can't anonymise them right now)
Update: If I ssh onto my self-hosted ubuntu 22.04 github runner and run the dotnet-gitversion command manually I get the same issue:
mike.clayton@ghrunner01:/opt/actions-runner/_work/devops-github-runners/devops-github-runners$ dotnet-gitversion /opt/actions-runner/_work/devops-github-runners/devops-github-runners /output json /output buildserver
INFO [04/22/24 18:38:51:93] Working directory: /opt/actions-runner/_work/devops-github-runners/devops-github-runners
unsupported extension name extensions.worktreeconfig
INFO [04/22/24 18:38:51:97] Done writing
Temporary workaround is placing this between the setup and execute action:
- name: Temporary workaround for GitVersion
continue-on-error: true
shell: bash
run: |
git config --unset-all extensions.worktreeconfig
# See https://github.com/GitTools/actions/issues/1115
EDIT: added continue-on-error: true since the command is throwing errorcode 5 since 2024-04-26. Looks like this issue only occurred between 2024-04-22 and 2024-04-26..
@pascalgulikers - just found the same workaround :-).
I put it straight after the actions/checkout@v4 and before both gitversion steps, which works as well.
Temporary workaround is placing this between the
setupandexecuteaction:- name: Temporary workaround for GitVersion continue-on-error: true shell: bash run: | git config --unset-all extensions.worktreeconfig # See https://github.com/GitTools/actions/issues/1115EDIT: added
continue-on-error: truesince the command is throwing errorcode 5 since 2024-04-26. Looks like this issue only occurred between 2024-04-22 and 2024-04-26..
This works too, if you don't want to disable error checking in the entire step:
if (git config --get extensions.worktreeconfig > /dev/null); then
git config --unset-all extensions.worktreeconfig
fi
This should be fixed in https://github.com/actions/checkout/releases/tag/v4.1.4