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
.NET Framework (Windows-only) or .NET Core: .NET 8.0.201
Environment (local platform and source/target platforms): Windows 11 for ARM in Parallels w/Macbook Pro host
Steps to Reproduce:
Create a new SQL project by running: dotnet new -i Microsoft.Build.Sql.Templates and then dotnet new sqlproj -n TestSqlProj
Open the SQL project in Visual Studio 2022 or 2022 Preview.
Rebuild the project.
Notice the build error:
Rebuild started at 3:13 PM...
------ Rebuild All started: Project: TestSqlProj, Configuration: Debug Any CPU ------
C:\Program Files\Microsoft Visual Studio\2022\Preview\MSBuild\Current\Bin\Roslyn\csc.exe /noconfig /nowarn:NU1701,NU5128,1701,1702,2008 /fullpaths /nostdlib+ /errorreport:prompt /warn:4 /define:DEBUG;TRACE /errorendlocation /preferreduilang:en-US /highentropyva+ /reference:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.7.2\mscorlib.dll" /debug+ /debug:full /optimize- /out:obj\Debug\TestSqlProj.dll /subsystemversion:6.00 /target:library /warnaserror- /utf8output /langversion:7.3 "C:\Users\justintoth\AppData\Local\Temp.NETFramework,Version=v4.7.2.SqlClrAttributes.cs"
Loading project references...
C:\Program Files\Microsoft Visual Studio\2022\Preview\MSBuild\Microsoft\VisualStudio\v17.0\SSDT\Microsoft.Data.Tools.Schema.SqlTasks.targets(544,5): Error: MSB4018: The "SqlBuildTask" task failed unexpectedly.
System.IO.DirectoryNotFoundException: Could not find a part of the path 'C:\MAC\HOME\DOWNLOADS\TEST\TESTSQLPROJ\OBJ\DEBUG\TESTSQLPROJ.DLL'.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share)
at Microsoft.Data.Tools.Schema.Sql.SqlClr.AssemblyParser.Process(String filename, IDictionary2 clrToSqlTypes) at Microsoft.Data.Tools.Schema.Sql.SchemaModel.SqlModelBuilder.AddAssemblyReference(CustomSchemaData customData) at Microsoft.Data.Tools.Schema.Sql.SchemaModel.SqlModelBuilder.Add(CustomSchemaData customSchemaData) at Microsoft.Data.Tools.Schema.SchemaModel.ModelBuilder.AddOrUpdate(CustomSchemaData customSchemaData) at Microsoft.Data.Tools.Schema.Sql.Build.SqlTaskHost.AddOrUpdate(CustomSchemaData customSchemaData) at Microsoft.Data.Tools.Schema.Tasks.Sql.TaskHostLoader.ProcessReferences(TaskLoggingHelper providedLogger, SqlTaskHost host, ErrorManager errors) at Microsoft.Data.Tools.Schema.Tasks.Sql.TaskHostLoader.LoadImpl(ITaskHost providedHost, TaskLoggingHelper providedLogger) at Microsoft.Data.Tools.Schema.Tasks.Sql.TaskHostLoader.Load(ITaskHost providedHost, TaskLoggingHelper providedLogger) at Microsoft.Data.Tools.Schema.Tasks.Sql.SqlBuildTask.ExecuteLoadTaskHostStep() at Microsoft.Data.Tools.Schema.Tasks.Sql.SqlBuildTask.ExecuteStep(Func1 step)
at Microsoft.Data.Tools.Schema.Tasks.Sql.SqlBuildTask.ExecuteTask()
at Microsoft.Data.Tools.Schema.Tasks.Sql.DataTask.Execute()
at Microsoft.Build.BackEnd.TaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.d__26.MoveNext()
Done building project "TestSqlProj.sqlproj" -- FAILED.
Because it's complaining about an obj directory, I tried cleaning in VS as well as manually deleting the bin and obj folders, but the build error persists.
When the build fails, can you check to see if this file exists, ignoring the upper case? C:\MAC\HOME\DOWNLOADS\TEST\TESTSQLPROJ\OBJ\DEBUG\TESTSQLPROJ.DLL
Can you try with SDK version 2.0.0-preview.1 which no longer creates/requires the DLL assembly?
This may be because of case-sensitive UNIX path despite being run on Windows while technically still on a Mac.
Steps to Reproduce:
Because it's complaining about an obj directory, I tried cleaning in VS as well as manually deleting the bin and obj folders, but the build error persists.
sqlproj file:
The text was updated successfully, but these errors were encountered: