csharpier icon indicating copy to clipboard operation
csharpier copied to clipboard

csharpier-repos has files that encoding detection fails on

Open belav opened this issue 4 years ago • 0 comments

The code below returns null for encoding on a few files. It does this even after they are written out with UTF8

            var detectionResult = CharsetDetector.DetectFromFile(file);
            var encoding = detectionResult?.Detected?.Encoding;

The files are from the aspnetcore repository - /aspnetcore/src/Shared/test/Shared.Tests/UrlDecoderTests.cs /aspnetcore/src/Razor/Microsoft.AspNetCore.Razor.Language/src/BoundAttributeDescriptorComparer.cs /aspnetcore/src/Razor/Microsoft.AspNetCore.Razor.Language/src/TagHelperDescriptorComparer.cs /aspnetcore/src/Servers/Kestrel/shared/KnownHeaders.cs

belav avatar Apr 12 '21 21:04 belav