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

Resizetizer error where appicon_background.png is in use by another process #12653

Closed
vsfeedback opened this issue Jan 13, 2023 · 3 comments
Closed
Labels
area-single-project Splash Screen, Multi-Targeting, MauiFont, MauiImage, MauiAsset, Resizetizer s/needs-repro Attach a solution or code which reproduces the issue t/bug Something isn't working

Comments

@vsfeedback
Copy link

This issue has been moved from a ticket on Developer Community.


When this happens a restart of VS2022 usually resolves it, but not always.
Error is:
/usr/local/share/dotnet/packs/Microsoft.Maui.Resizetizer.Sdk/6.0.424/targets/Microsoft.Maui.Resizetizer.targets(9,9): Error MAUI0000: System.IO.IOException: The process cannot access the file '/Users/dfgdgdf/Projects/maui-samples/6.0/PlatformIntegration/InvokePlatformCodeDemos/InvokePlatformCodeDemos/obj/Debug/net6.0-android/resizetizer/r/mipmap-mdpi/appicon_background.png' because it is being used by another process.
at Microsoft.Win32.SafeHandles.SafeFileHandle.Init(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
at System.IO.Strategies.OSFileStreamStrategy..ctor(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
at System.IO.Strategies.FileStreamHelpers.ChooseStrategy(FileStream fileStream, String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, Int64 preallocationSize)
at System.IO.File.Create(String path)
at Microsoft.Maui.Resizetizer.SkiaSharpTools.Save(String destination, SKBitmap tempBitmap) in D:\a_work\1\s\src\SingleProject\Resizetizer\src\SkiaSharpTools.cs:line 143
at Microsoft.Maui.Resizetizer.SkiaSharpTools.Resize(DpiPath dpi, String destination, Double additionalScale, Boolean dpiSizeIsAbsolute) in D:\a_work\1\s\src\SingleProject\Resizetizer\src\SkiaSharpTools.cs:line 64
at Microsoft.Maui.Resizetizer.AndroidAdaptiveIconGenerator.ProcessBackground(List1 results, DirectoryInfo fullIntermediateOutputPath) in D:\a\_work\1\s\src\SingleProject\Resizetizer\src\AndroidAdaptiveIconGenerator.cs:line 53 at Microsoft.Maui.Resizetizer.AndroidAdaptiveIconGenerator.Generate() in D:\a\_work\1\s\src\SingleProject\Resizetizer\src\AndroidAdaptiveIconGenerator.cs:line 41 at Microsoft.Maui.Resizetizer.ResizetizeImages.ProcessAppIcon(ResizeImageInfo img, ConcurrentBag1 resizedImages) in D:\a_work\1\s\src\SingleProject\Resizetizer\src\ResizetizeImages.cs:line 133
at Microsoft.Maui.Resizetizer.ResizetizeImages.<>c__DisplayClass26_0.b__0(ResizeImageInfo img) in D:\a_work\1\s\src\SingleProject\Resizetizer\src\ResizetizeImages.cs:line 56
at Microsoft.Maui.Resizetizer.AsyncTaskExtensions.<>c__DisplayClass0_0`1.b__0(TSource s) in D:\a_work\1\s\src\SingleProject\Resizetizer\src\AsyncTaskExtensions.cs:line 21 (MAUI0000) (InvokePlatformCodeDemos)


Original Comments

Feedback Bot on 9/4/2022, 07:46 PM:

(private comment, text removed)

Paul Wang [MSFT] on 9/5/2022, 02:36 AM:

(private comment, text removed)

John Hair on 9/14/2022, 00:15 PM:

(private comment, text removed)

John Hair on 9/15/2022, 02:29 PM:

(private comment, text removed)

Feedback Bot on 9/13/2022, 08:31 PM:

(private comment, text removed)

Paul Wang [MSFT] on 9/14/2022, 07:36 PM:

(private comment, text removed)

Feedback Bot on 9/15/2022, 07:31 PM:

(private comment, text removed)

Feedback Bot on 1/4/2023, 10:31 PM:

(private comment, text removed)


Original Solutions

(no solutions)

@jsuarezruiz jsuarezruiz added the area-single-project Splash Screen, Multi-Targeting, MauiFont, MauiImage, MauiAsset, Resizetizer label Jan 16, 2023
@jsuarezruiz
Copy link
Contributor

Steps:

  1. Add a new Maui solution.
  2. Then in the solution, add another Maui APP project (not library).
  3. Then in the first app project, add a project reference to the 2nd app project.
  4. Attempt to run the first app project.

@jsuarezruiz jsuarezruiz added the s/needs-repro Attach a solution or code which reproduces the issue label Jan 16, 2023
@ghost
Copy link

ghost commented Jan 16, 2023

Hi @vsfeedback. We have added the "s/needs-repro" label to this issue, which indicates that we require steps and sample code to reproduce the issue before we can take further action. Please try to create a minimal sample project/solution or code samples which reproduce the issue, ideally as a GitHub repo that we can clone. See more details about creating repros here: https://github.com/dotnet/maui/blob/main/.github/repro.md

This issue will be closed automatically in 7 days if we do not hear back from you by then - please feel free to re-open it if you come back to this issue after that time.

@ghost ghost added the s/no-recent-activity Issue has had no recent activity label Jan 20, 2023
@ghost
Copy link

ghost commented Jan 20, 2023

This issue has been automatically marked as stale because it has been marked as requiring author feedback to reproduce the issue but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment. If it is closed, feel free to comment when you are able to provide the additional information and we will re-investigate.

@ghost ghost closed this as completed Jan 23, 2023
@ghost ghost locked as resolved and limited conversation to collaborators Feb 22, 2023
@samhouts samhouts added the t/bug Something isn't working label Feb 5, 2024
@ghost ghost removed the s/no-recent-activity Issue has had no recent activity label Feb 5, 2024
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-single-project Splash Screen, Multi-Targeting, MauiFont, MauiImage, MauiAsset, Resizetizer s/needs-repro Attach a solution or code which reproduces the issue t/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants