You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Attempting to compile a .NET Framework class library.
Is this a new or an existing app?
The app is in production, and I have upgraded to a new version of MSAL
Issue description and reproduction steps
Trying to compile a .NET Framework 4.7.2 class library that references Microsoft.Identity.Client.Desktop v4.52.0 higher (I have been testing using v4.59.0) fails with the following error:
Severity Code Description Project File Line Suppression State
Error CS2001 Source file 'C:\Temp\TestAssembly\obj\Debug\TestAssembly.AssemblyInfo.cs' could not be found. TestAssembly C:\Temp\TestAssembly\CSC 1 Active
Compilation works correctly against v4.51.0.
On further investigating, I have discovered that for some reason, using v4.52.0 higher adds the following to the csc.exe command line:
/embed:obj\Debug\TestAssembly.AssemblyInfo.cs
It is this switch is what is causing the failure.
Relevant code snippets
An example .csproj file that re-creates this problem:
I should have looked through the open issues, as is a duplicate of #4485. I am going to leave this issue open for now, as it is a serious problem that is preventing me from upgrading our production code beyond v4.51.0.
Library version used
4.59.0
.NET version
.NET Framework v4.7.2
Scenario
Attempting to compile a .NET Framework class library.
Is this a new or an existing app?
The app is in production, and I have upgraded to a new version of MSAL
Issue description and reproduction steps
Trying to compile a .NET Framework 4.7.2 class library that references Microsoft.Identity.Client.Desktop v4.52.0 higher (I have been testing using v4.59.0) fails with the following error:
Compilation works correctly against v4.51.0.
On further investigating, I have discovered that for some reason, using v4.52.0 higher adds the following to the csc.exe command line:
/embed:obj\Debug\TestAssembly.AssemblyInfo.cs
It is this switch is what is causing the failure.
Relevant code snippets
An example
.csproj
file that re-creates this problem:Expected behavior
The class library should compille...(!)
Regression
4.51.0
Solution and workarounds
I have not been able to find any way to workaround this problem, despite spending several hours investigating the problem.
If you change the following:
<GenerateAssemblyInfo>False</GenerateAssemblyInfo>
to
<GenerateAssemblyInfo>True</GenerateAssemblyInfo>
then it does compile but the problem than manifests in any other assembly that references the test assembly...
The text was updated successfully, but these errors were encountered: