Skip to content
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

Arcade insertions fail on dotnet/templating -> release/6.0.3xx & release/6.0.4xx #12740

Closed
1 of 5 tasks
YuliiaKovalova opened this issue Mar 1, 2023 · 16 comments
Closed
1 of 5 tasks
Assignees

Comments

@YuliiaKovalova
Copy link
Member

YuliiaKovalova commented Mar 1, 2023

Build

https://dev.azure.com/dnceng-public/public/_build/results?buildId=187934&view=logs&j=2f0d093c-1064-5c86-fc5b-b7b1eca8e66a&t=d2b639a6-cb19-5f1f-66fd-8047f66b3026

Build leg reported

Build

Pull Request

dotnet/templating#6178

Action required for the engineering services team

To triage this issue (First Responder / @dotnet/dnceng):

  • Open the failing build above and investigate
  • Add a comment explaining your findings

If this is an issue that is causing build breaks across multiple builds and would get benefit from being listed on the build analysis check, follow the next steps:

  1. Add the label "Known Build Error"
  2. Edit this issue and add an error string in the Json below that can help us match this issue with future build breaks. You should use the known issues documentation
{
   "ErrorMessage" : "Could not load file or assembly */tools/Microsoft.DotNet.Arcade.Sdk.dll",
   "BuildRetry": false,
   "ErrorPattern": "Could not load file or assembly *",
   "ExcludeConsoleLog": false
}

Release Note Category

  • Feature changes/additions
  • Bug fixes
  • Internal Infrastructure Improvements

Release Note Description

Additional information about the issue reported

No response

@oleksandr-didyk
Copy link
Contributor

Updated the error description, taking a look at it

@oleksandr-didyk oleksandr-didyk self-assigned this Mar 1, 2023
@oleksandr-didyk
Copy link
Contributor

oleksandr-didyk commented Mar 1, 2023

It seems that the MSBuild property pointing to the location of Arcade's tool DLLs is incorrect in the source-build intermediate, hence the exception of missing DLL in the logs.

Versions of the Arcade's intermediate up to February 15th seem to have the correct path set (from BuildTasks.props inside the intermediate, second property):

<Project>
  <PropertyGroup>
    <ArcadeSdkBuildTasksAssembly Condition="'$(MSBuildRuntimeType)' != 'Core'">$(MSBuildThisFileDirectory)net472\Microsoft.DotNet.Arcade.Sdk.dll</ArcadeSdkBuildTasksAssembly>
    <ArcadeSdkBuildTasksAssembly Condition="'$(MSBuildRuntimeType)' == 'Core'">$(MSBuildThisFileDirectory)net6.0\Microsoft.DotNet.Arcade.Sdk.dll</ArcadeSdkBuildTasksAssembly>
  </PropertyGroup>
</Project>

Versions after though, including the one used in this build, have the TFM missing from the path:

<Project>
  <PropertyGroup>
    <ArcadeSdkBuildTasksAssembly Condition="'$(MSBuildRuntimeType)' != 'Core'">$(MSBuildThisFileDirectory)net472\Microsoft.DotNet.Arcade.Sdk.dll</ArcadeSdkBuildTasksAssembly>
    <ArcadeSdkBuildTasksAssembly Condition="'$(MSBuildRuntimeType)' == 'Core'">$(MSBuildThisFileDirectory)\Microsoft.DotNet.Arcade.Sdk.dll</ArcadeSdkBuildTasksAssembly>
  </PropertyGroup>
</Project>

while the relative path of the DLL remained the same:
image

Since the source-code differs from what ends up in the intermediate, I'm guessing source-build somewhere alters the contents of the file / substitutes the file completely. I failed to find where exactly this is done though, so pinging @dotnet/source-build-internal for some help here

@mmitche
Copy link
Member

mmitche commented Mar 1, 2023

That's pretty bizarre. The change on the 14th was an SDK update. I'm rerunning the commit before to eliminate any environmental factors that may have contributed. Super weird.

@mmitche
Copy link
Member

mmitche commented Mar 1, 2023

@mmitche
Copy link
Member

mmitche commented Mar 1, 2023

The source build intermediate package from the older build looks fine.

@mmitche
Copy link
Member

mmitche commented Mar 1, 2023

The replacement happens in https://github.com/dotnet/arcade/blob/release/6.0/eng/SourceBuild.props#L20-L39. The issue here is 5c3a033 removed 5c3a033#diff-6a28d92de8923be8821f2123541dc23c8ad0359c96117709e6d49e752c0303d2L8.

This means that the property is empty when we generate the file.

@MichaelSimons do you know whether this target is still required in 6.0? As far as I can tell, it's gone in 7.0 onwards and I can't find a similar target elsewhere.

@MichaelSimons
Copy link
Member

I don't have the history here. @crummel - do you know?

@MichaelSimons
Copy link
Member

By looking at things, I think it is still required in 6.0.

@crummel
Copy link
Contributor

crummel commented Mar 2, 2023

Yeah, it looks like we still have a couple places where we specifically change the TFM for source-build in 6.0, e.g. https://github.com/dotnet/arcade/blob/release/6.0/src/Common/Microsoft.Arcade.Common/Microsoft.Arcade.Common.csproj#L5 and https://github.com/dotnet/arcade/blob/release/6.0/src/Microsoft.DotNet.Arcade.Sdk/Microsoft.DotNet.Arcade.Sdk.csproj#L5. We've taken a different approach in some cases (I think F#) where we change the path in the Sdk.props/etc files but if I remember correctly we couldn't do that here because we didn't have access to DotNetBuildFromSource or the Arcade path was not actually variable at the time, something like that.

@JanKrivanek
Copy link
Member

@MichaelSimons will the inability to update the arcade for 6.0.3xx and 6.0.4xx Templating branches cause issues during the source build? In another words - might this be perceived as servicing blocker? (@mmitche, @wtgodbe)

@MichaelSimons
Copy link
Member

@MichaelSimons will the inability to update the arcade for 6.0.3xx and 6.0.4xx Templating branches cause issues during the source build? In another words - might this be perceived as servicing blocker? (@mmitche, @wtgodbe)

No, source-build is only supported in the 1xx feature band.

@JanKrivanek
Copy link
Member

Thank you for the answer!
Oh - that's great! So I suppose that this arcade upgrade blocker does not need to be considered servicing blocker. If anybody believes otherwise - please let us know.

@YuliiaKovalova
Copy link
Member Author

Hi everyone,

any updates on it? Do we really need to merge these insertions to dotnet/templating repo?

@mmitche
Copy link
Member

mmitche commented Mar 15, 2023

It's not critical for the next release, but I would like to solve the issue.

@YuliiaKovalova
Copy link
Member Author

one more failing PR dotnet/templating#6274

mmitche added a commit to mmitche/arcade that referenced this issue Mar 16, 2023
When I moved around properties to support NetCurrent, etc. in 6.0, the TFM replacement in arcade's build property files broke because the TFM property was not defined. Fix this by simply hardcoding the property value. It's not ever going to change.
mmitche added a commit that referenced this issue Mar 17, 2023
When I moved around properties to support NetCurrent, etc. in 6.0, the TFM replacement in arcade's build property files broke because the TFM property was not defined. Fix this by simply hardcoding the property value. It's not ever going to change.
@YuliiaKovalova
Copy link
Member Author

thank you for the fix

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants