-
Notifications
You must be signed in to change notification settings - Fork 4
fix: include libraries #8
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
Conversation
|
LGTM |
|
Looks like a bug in Rider. Code compiles without these meaning they aren't needed. I'll double check this when I hop on in about an hour. |
|
Fully confirmed, this is indeed a rider bug. C# 10 / .NET 6 added a new global usings feature. You can read up on it here. As for how this is causing rider to detect this as an error, .NET 6 Preview 7 (the latest preview release) added commonly used namespaces as global using's in web projects. You can see the tracking item at dotnet/aspnetcore#32451 and the implementation in dotnet/sdk#18459. After a build you can open the file // <autogenerated />
global using global::System;
global using global::System.Collections.Generic;
global using global::System.IO;
global using global::System.Linq;
global using global::System.Net.Http;
global using global::System.Threading;
global using global::System.Threading.Tasks;
global using global::System.Net.Http.Json;
global using global::Microsoft.AspNetCore.Builder;
global using global::Microsoft.AspNetCore.Hosting;
global using global::Microsoft.AspNetCore.Http;
global using global::Microsoft.AspNetCore.Routing;
global using global::Microsoft.Extensions.Configuration;
global using global::Microsoft.Extensions.DependencyInjection;
global using global::Microsoft.Extensions.Hosting;
global using global::Microsoft.Extensions.Logging;Rider does not appear to be analyzing this file for whatever reason while Visual Studio and VS Code both do. This should get fixed in a future rider update. Keep in mind Rider does not fully support .NET 6 yet, can check out their post on it here. This is actually a nice new feature in .NET 6, so would really like to embrace it. Visual Studio 2022 & VS Code are fully supported and updated every month to support the latest preview sdk updates. This should be less of an issue as we get closer to the GA release of .NET 6 in November. RC1 will be out on the 14th. Until a fix is added to rider we could either just have you guys ignore the bug in rider or we could add Ideas/thoughts? |
|
Resolved with latest rider versions. |

PR Title
Added include libraries
PR Description
Added include libraries
Fixes #7