-
Notifications
You must be signed in to change notification settings - Fork 653
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
[Bug] Azure DevOps UseGitVersion@5 task and GitVersion 5.2.4 produces an error "AssemblyInfoFilename file not found at null" when UpdateAssemblyInfo: true
is set
#2225
Comments
We are currently experiencing the same issue. No solution found yet. |
We have encountered the same issue today. Pipeline YAML
Gitversion YAML config
|
If I specify the full path to the assembly info file
We get a slightly different error:
The path to the assembly file is correct so that is not the issue. |
So, apparently using the full absolute path to the AssemblyInfo.cs file seems to work:
Using a shared GlobalAssemblyInfo.cs file combined with this configuration might be a suitable workaround. But I would expect something like this to work just fine:
And perhaps this could even be the default convention? The only remaining issue at this point is that we now get this warning:
Which seems weird, because we don't have any version-related properties in the assembly info file:
|
Sadly, I have multiple
- task: UseGitVersion@5
displayName: gitversion
inputs:
versionSpec: '5.x'
updateAssemblyInfo: true
updateAssemblyInfoFilename: '**/AssemblyInfo.cs' As would I, but it does not. It was also unnecessary to be explicit about While I appreciate the sentiments and suggestions expressed above, an Also, since a file pattern such as As an aside, I've also noticed a comparatively large performance degradation in |
Hi @arturcic Now that this issue is closed, do we simply need to wait for the - task: UseGitVersion@5
inputs:
versionSpec: '5.x'
updateAssemblyInfo: true |
Kind of yes, but I test with the GitTools extension not UseGitversion. As we're moving to the GitTools extension, the UseGitversion will be obsolete |
🎉 This issue has been resolved in version 5.3.0 🎉 Your GitReleaseManager bot 📦🚀 |
@arturcic Was the File Globbing implemented this version? I just tried the UseGitVersion task with 5.3.2, checking However |
I can't seem to get it to work
##[error]Error: AssemblyInfoFilename file not found at null |
Use GitTools instead of UseGitversion |
With GitTools I get Task : Execute GitVersion Task ##[error]Error: AssemblyInfoFilename file not found at undefined |
That is weird, do you have any assembly info? |
Looks like it cannot find one |
Yes its in the Properties folder of the project |
Is it public project? |
Its a private project .. I can share it using email? |
Works for me |
I'm also having the same issue with GitTools on Azure DevOps.
Extract from the build YAML:
I've also tried without specifying the AssemblyInfo Filename:
Build task:
|
I got a similar issue and opened an issue in the GitVersion Actions repo. |
I encountered this bug in Version 5.3.x, should I create a new Issue? |
Has this been corrected yet? |
GitTools/actions#316 should fix this. |
Describe the bug
I have recently been updating pipelines to use the
UseGitVersion@5
task, replacing the obsoleteGitVersion@5
task. For the most part, this has been easy, and I did not encounter any problems until I switched out the task on a pipeline which use GitVersion to update theAssemblyInfo.cs
files for a .Net Framework solution. When run, the build fails on theUseGitVersion@5
task, with the error message:The task is defined in my pipeline as per the example in the GitVersion docs:
Expected Behavior
The
UseGitVersion@5
task should update allAssemblyInfo.cs
files under the repositoryActual Behavior
Task execution fails with the error
AssemblyInfoFilename file not found at null
.Possible Fix
Unfortunately, I have nothing concrete to offer beyond wild speculation.
Steps to Reproduce
This may be reproduced using the simple pipeline below, in a repo containing a .Net Framework solution with projects that include
AssemblyInfo.cs
files.Gitversion.yml
file also attached.See the attached log from pipeline task execution
UserGitVersionPipelineTaskLog.log
with debugging enabled
Context
No longer able to automate the versioning of assemblies with
UseGitVersion@5
as ws possible withGitVersion@5
task.Your Environment
Azure DevOps Pipelines running on MS hosted Windows Agent
windows-latest
MS hosted agentUseGitVersion@5
- v5.1.2Sample Pipeline
Sample
GitVersion.yml
config used...nothing to see here reallyThe text was updated successfully, but these errors were encountered: