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

fix: implicitly run dotnet restore #8419

Merged
merged 1 commit into from
Feb 18, 2023
Merged

fix: implicitly run dotnet restore #8419

merged 1 commit into from
Feb 18, 2023

Conversation

yufeih
Copy link
Contributor

@yufeih yufeih commented Feb 18, 2023

Building a project without any NuGet package reference requires dotnet restore in certain cases for MSBuildWorkspace to generate a compilation: dotnet/roslyn#36072, otherwise predefined types are not imported:

error CS0518: Predefined type 'System.Object' is not defined or imported

Run an implicit dotnet restore for csproj and sln, which can be turned off using the noRestore config.

#3177

@yufeih yufeih marked this pull request as ready for review February 18, 2023 06:28
@codecov
Copy link

codecov bot commented Feb 18, 2023

Codecov Report

Base: 77.10% // Head: 77.12% // Increases project coverage by +0.02% 🎉

Coverage data is based on head (8d62ef6) compared to base (70c81a5).
Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8419      +/-   ##
==========================================
+ Coverage   77.10%   77.12%   +0.02%     
==========================================
  Files         860      860              
  Lines       30773    30778       +5     
==========================================
+ Hits        23726    23738      +12     
+ Misses       7047     7040       -7     
Impacted Files Coverage Δ
src/Microsoft.DocAsCode.Dotnet/DotnetApiCatalog.cs 96.22% <100.00%> (+0.07%) ⬆️
...de.Dotnet/ExtractMetadata/ExtractMetadataConfig.cs 100.00% <100.00%> (ø)
...de.Dotnet/ExtractMetadata/ExtractMetadataWorker.cs 83.64% <100.00%> (+0.15%) ⬆️
...crosoft.DocAsCode.Dotnet/MetadataJsonItemConfig.cs 100.00% <100.00%> (ø)
...osoft.DocAsCode.Tests.Common/TestLoggerListener.cs 94.33% <0.00%> (+1.88%) ⬆️
src/Microsoft.DocAsCode.Common/Git/GitUtility.cs 78.19% <0.00%> (+3.19%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@yufeih yufeih merged commit 16a1ff2 into main Feb 18, 2023
@yufeih yufeih deleted the feature/200 branch February 18, 2023 06:45
@yufeih yufeih added the bug-fix Makes the pull request to appear in "Bug Fixes" section of the next release note label Mar 5, 2023
@yufeih
Copy link
Contributor Author

yufeih commented Mar 5, 2023

Fixes #8465

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug-fix Makes the pull request to appear in "Bug Fixes" section of the next release note
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant