-
-
Notifications
You must be signed in to change notification settings - Fork 851
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
SaveAsWebpAsync throws IndexOutOfRangeException in UWP published app #2567
Comments
Normally we wouldn't support issues raised against previous major versions (we're on v3 now) but I'm not sure what target frameworks UWP support. The issue itself is not an ImageSharp one but rather appears to me to be a bug in the compiler. @Sergio0694 Apologies for the tag but you know a lot more about UWP than me. What are your thoughts? |
UWP is picking up the .NET Standard 2.0 target (it uses the
Yeah this is a weird one, especially because it also repros with sideloaded Release packages (meaning ones you compiled locally), yet it doesn't with a normal Release build from VS. Impossible to say exactly what's causing that without just debugging the app. I do remember using ImageSharp on UWP in the past, and it worked (my app Legere is using ...Honestly I think your best bet for UWP right now is try downgrading the ImageSharp package step by step until you find a previous release that happens to work 🙃 |
Thanks @Sergio0694 appreciate it!! @brunomuratore when you say the following
I'm assuming you mean input images. Does saving as other image formats (jpg, png, etc) work? |
Shouldn't UWP users be migrating to WinUI 3? |
Prerequisites
DEBUG
andRELEASE
modeImageSharp version
2.1.6
Other ImageSharp packages and versions
none
Environment (Operating system, version and so on)
Win 11 and Win 10 on any* version
.NET Framework version
UWP x64 app (Target: win11 22H2, Min: win10 1903), c# 9.0
Description
IndexOutOfRangeException is thrown when running
SaveAsWebpAsync
on a published UWP app, independently of which image is loaded into the stream, any image will fail, any format will fail. The same code runs fine when running the UWP app directly from Visual Studio, either Debug or Release.Steps to Reproduce
The code work fine when running the app from Visual Studio, either from Debug or Release modes.
But it will fail only if:
If I try to create a sample app to try demostrate the issue, it works, although the code is being tested is virtually the same.
Images
Any image, any format.
The text was updated successfully, but these errors were encountered: