Unable to run smoke tests following README instructions
jozkee opened this issue · 5 comments
Hi all, I'm working on a breaking change in .NET on an API that is used by src/SourceBuild/content/test/Microsoft.DotNet.SourceBuild.SmokeTests/SdkContentTests.cs and I want to verify if the smoke tests would be affected.
I tried to build myself and run the smoke test with build.sh --run-smoke-test as described here but I couldn't make it work:
david@ubuntu:~/installer$ src/SourceBuild/content/build.sh --run-smoke-test
ERROR: /home/david/installer/src/SourceBuild/content is not a git repository. Please run prep.sh add initialize Source Link metadata.
I ran prep.sh and that downloads a source-build prebuilt but above command is still unblocked.
Any help here would be appreciated and updating readmes would be beneficial for the community as well.
This is meant to be run from within the VMR. All content within src/SourceBuild/content of the installer gets mirrored to the root of the VMR. So the build.sh script is at the root of the VMR.
Thanks. Do you know what should I set into SMOKE_TESTS_MSFT_SDK_TARBALL_PATH
and SMOKE_TESTS_SDK_TARBALL_PATH
? The test I care for is being skipped and many other tests fail with System.InvalidOperationException : Tarball path '' specified in does not exist.
btw, I ran build.sh first and that finished with errors, not sure if that may be related:
/home/david/dotnet/repo-projects/Directory.Build.targets(221,5): error MSB3073: The command "/home/david/dotnet/src/source-build-reference-packages/build.sh --ci --configuration Release --restore --build --pack --publish -bl /p:ArcadeBuildFromSource=true /p:CopyWipIntoInnerSourceBuildRepo=true /p:DotNetBuildOffline=true /p:CopySrcInsteadOfClone=true /p:DotNetPackageVersionPropsPath="/home/david/dotnet/artifacts/obj/x64/Release/PackageVersions.source-build-reference-packages.props" /p:AdditionalSourceBuiltNupkgCacheDir="/home/david/dotnet/artifacts/obj/x64/Release/blob-feed/packages/" /p:ReferencePackageNupkgCacheDir="/home/david/dotnet/prereqs/packages/reference/" /p:PreviouslySourceBuiltNupkgCacheDir="/home/david/dotnet/prereqs/packages/previously-source-built/" /p:SourceBuildUseMonoRuntime= /p:DotNetBuildVertical=false /p:MicrosoftNetCoreIlasmPackageRuntimeId=linux-x64 /p:LocalNuGetPackageCacheDirectory=/home/david/dotnet/artifacts/obj/source-build-reference-package-cache /v:minimal >> /home/david/dotnet/artifacts/logs/source-build-reference-packages.log 2>&1" exited with code 1. [/home/david/dotnet/repo-projects/source-build-reference-packages.proj]
bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
##vso[task.setvariable variable=Artifacts;isSecret=false;isOutput=true]/home/david/dotnet/src/source-build-reference-packages/artifacts
##vso[task.setvariable variable=Artifacts.Toolset;isSecret=false;isOutput=true]/home/david/dotnet/src/source-build-reference-packages/artifacts/toolset
##vso[task.setvariable variable=Artifacts.Log;isSecret=false;isOutput=true]/home/david/dotnet/src/source-build-reference-packages/artifacts/log/Release
##vso[task.setvariable variable=Temp;isSecret=false;isOutput=true]/home/david/dotnet/src/source-build-reference-packages/artifacts/tmp/Release
##vso[task.setvariable variable=TMP;isSecret=false;isOutput=true]/home/david/dotnet/src/source-build-reference-packages/artifacts/tmp/Release
##vso[task.setvariable variable=NUGET_PLUGIN_HANDSHAKE_TIMEOUT_IN_SECONDS;isSecret=false;isOutput=true]20
##vso[task.setvariable variable=NUGET_PLUGIN_REQUEST_TIMEOUT_IN_SECONDS;isSecret=false;isOutput=true]20
bash : error : setlocale: LC_ALL: cannot change locale (en_US.UTF-8) [/home/david/dotnet/prereqs/packages/restored/ArcadeBootstrapPackage/microsoft.dotnet.arcade.sdk/9.0.0-beta.23565.1/tools/Build.proj]
##vso[task.logissue type=error;sourcepath=bash;linenumber=0;columnnumber=0;code=;]setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
bash : error : setlocale: LC_ALL: cannot change locale (en_US.UTF-8) [/home/david/dotnet/prereqs/packages/restored/ArcadeBootstrapPackage/microsoft.dotnet.arcade.sdk/9.0.0-beta.23565.1/tools/Build.proj]
##vso[task.logissue type=error;sourcepath=bash;linenumber=0;columnnumber=0;code=;]setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
In order to help, I need to better understand how you intend to test things. Are you bringing your own already built SDK containing your API change that you'll compile the test project against? Or are you intending to apply your change to the VMR in order to produce a source-built SDK that will then be used to compile the test project?
What's the way that works most incrementally? I was expecting to spin a codespace, pull my change and test.
I found https://github.com/dotnet/dotnet/tree/main/.devcontainer#readme. I executed:
/workspaces/synchronize-vmr.sh \
--repository runtime:05265df5e38544415b673ef3a3774d198ace0560 \
--remote runtime:https://github.com/Jozkee/runtime
and then ./prep.sh && ./build.sh --online
but that is now also giving me unrelated errors:
Build FAILED.
/workspaces/dotnet/src/runtime/artifacts/source-build/self/src/src/coreclr/tools/aot/crossgen2/Crossgen2RootCommand.cs(287,13): error CS0030: Cannot convert type 'System.Func<System.CommandLine.Help.HelpContext, bool>' to 'System.Action<System.CommandLine.Help.HelpContext>' [/workspaces/dotnet/src/runtime/artifacts/source-build/self/src/src/coreclr/tools/aot/crossgen2/crossgen2.csproj]
/workspaces/dotnet/src/runtime/artifacts/source-build/self/src/src/coreclr/tools/Common/CommandLineHelpers.cs(137,45): error CS1503: Argument 1: cannot convert from 'System.Func<System.CommandLine.Help.HelpContext, System.Collections.Generic.IEnumerable<System.Action<System.CommandLine.Help.HelpContext>>>' to 'System.Func<System.CommandLine.Help.HelpContext, System.Collections.Generic.IEnumerable<System.Func<System.CommandLine.Help.HelpContext, bool>>>' [/workspaces/dotnet/src/runtime/artifacts/source-build/self/src/src/coreclr/tools/aot/crossgen2/crossgen2.csproj]
/workspaces/dotnet/src/runtime/artifacts/source-build/self/src/src/coreclr/tools/aot/crossgen2/Program.cs(919,17): error CS0117: 'CliConfiguration' does not contain a definition for 'EnableParseErrorReporting' [/workspaces/dotnet/src/runtime/artifacts/source-build/self/src/src/coreclr/tools/aot/crossgen2/crossgen2.csproj]
0 Warning(s)
3 Error(s)
I think I will stop chasing validation and will just let the breaking change flow and act if needed. Thanks @mthalman.