dotnet6 project failing on static abstracts with preview features set to true

JJayy8/14/2022
C:\Users\Kellen James\source\Repos\ClemBot\ClemBot.Api\ClemBot.Api.Core\Features\Tags\Edit.cs(51,49): error CS8920: The
 interface 'IQueryResult<Edit.TagDto>' cannot be used as type argument. Static member 'IQueryResult<Edit.TagDto>.Succes
s(Edit.TagDto?)' does not have a most specific implementation in the interface. [C:\Users\Kellen James\source\Repos\Cle
mBot\ClemBot.Api\ClemBot.Api.Core\ClemBot.Api.Core.csproj]
C:\Users\Kellen James\source\Repos\ClemBot\ClemBot.Api\ClemBot.Api.Core\Features\Tags\SetCustomTagPrefix.cs(31,48): err
or CS8920: The interface 'IQueryResult<ulong>' cannot be used as type argument. Static member 'IQueryResult<ulong>.Succ
ess(ulong)' does not have a most specific implementation in the interface. [C:\Users\Kellen James\source\Repos\ClemBot\
ClemBot.Api\ClemBot.Api.Core\ClemBot.Api.Core.csproj]
    4 Warning(s)
    261 Error(s)
I am seeing this error attempting to use static abstracts in a .net 6 project
JJayy8/14/2022
this code works on other peoples machines fine, its on a 6.0.400 install of dotnet
JJayy8/14/2022
cc @tannergooding maybe? Static abstracts are sorta your wheel house
JJayy8/14/2022
    <PropertyGroup>
        <TargetFramework>net6.0</TargetFramework>
        <Nullable>enable</Nullable>
        <WarningsAsErrors>nullable</WarningsAsErrors>
        <LangVersion>preview</LangVersion>
        <EnablePreviewFeatures>True</EnablePreviewFeatures>
    </PropertyGroup>
JJayy8/14/2022
csproj
Ttannergooding8/14/2022
.net 6 has many limitations as not all runtime support is ghere
Ttannergooding8/14/2022
Also going camping until Wednesday, so little internet
JJayy8/14/2022
ahh ok, have fun
JJayy8/14/2022
ohh wow ok, so i upgraded my sdk from 6.0.1 -> 6.0.4 and it started failing for me
JJayy8/14/2022
fascinating
JJayy8/14/2022
this feels like a bug
OOrannis8/14/2022
Show code, but likely not a bug
JJayy8/14/2022
did this ship 5 days ago as part of 6.0.8 of the runtime?
OOrannis8/14/2022
Wouldn't surprise me
JJayy8/14/2022
thats fantastic lol
JJayy8/14/2022
-_-
JJayy8/14/2022
and code is this
public interface IQueryResult<T> : IResult<T, QueryStatus>
{
    static abstract IQueryResult<T> Success(T? val);
    static abstract IQueryResult<T> Invalid(T? val);
    static abstract IQueryResult<T> NotFound();
    static abstract IQueryResult<T> Conflict();
    static abstract IQueryResult<T> Forbidden();
}
Ppatrickk8/14/2022
for a moment i thought you had lied to us all about your name
JJayy8/14/2022
    public class Handler(ClemBotContext _context) : IRequestHandler<Command, IQueryResult<Model>>
    {
    }
JJayy8/14/2022
:ree:
Image
JJayy8/14/2022
this is quite unfortunate
JJayy8/14/2022
i am going to have to rewrite... everything for this
JJayy8/14/2022
and i cant write a conversion cuz its an interface :ree: