-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
MAUI Resizetizer 'file is being used by another process' error when referencing a .NET MAUI App from another .NET MAUI App #14082
Comments
I'm having this error a lot on clean builds, not referring to another MAUI app. However it only happens on clean builds, and only on the local machine. Clean CI builds in run without issue. When it occurs locally, I just try again a few times, and once it works and the good value is cached, the problem doesn't reoccur until I clean again. I have no idea why it happens like that, and how relevant it is, but maybe this information can be used to narrow down the issue? |
I think this is because you have 2 files with the same name? Are there multiple files named When it works, it is just the last one winning and it is arbitrary. If the images are different, you will end up with different images in the app each time. |
Hi @wqotipo5. We have added the "s/needs-info" label to this issue, which indicates that we have an open question for you before we can take further action. 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. |
Looking at your attached issue, I see 2 dotnet_bot files. As a result, the image processor is trying to process both at the same time and the file is locked. Is the images with the same name a desired feature? What would you use it for? Or is it just a coincidence? |
This issue has been automatically marked as stale because it has been marked as requiring author feedback 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. |
Probably a different issue than mine then. I definitely don't have multiple files with the same name. |
Can you attach a binlog? Maybe there is another issue somewhere. |
I'll get back to this once I encounter it again. That's bound to happen on Monday or Tuesday as I have to release an update of our app built with API 33 now that the service release is out 🎉 |
I haven't encountered this again, even though it happened quite often before. I'll tentatively call it fixed in the latest MAUI 7.0 service release. |
OK, let me close and maybe open a new issue if it happens again. I think what we will need is what projects have maui images/icons and see if there are any duplicate names across app/library projects. |
This is unfortunately an example of how MAUI simply is not yet mature. I received this exact same error by following the resolution for another issue. Initially I could not deploy to Android because it said it could not find a splash image. Android wants a MauiImage, not a MauiSplashScreen for some reason. So I copy over the splash.svg file and make it a MauiImage. Then when I try to build on iOS, I get this error. The solution is inelegant and trivial - rename the Android image splash2.svg. Still this is quite frustrating. |
Hello lovely human, thank you for your comment on this issue. Because this issue has been closed for a period of time, please strongly consider opening a new issue linking to this issue instead to ensure better visibility of your comment. Thank you! |
I too face this exact issue fairly often. not on every build, but maybe 1/3 of them. And I have no duplicate image files at all (actually just the default images + one png file I use). Curious if anyone else is still facing this and found a solution. |
Hello lovely human, thank you for your comment on this issue. Because this issue has been closed for a period of time, please strongly consider opening a new issue linking to this issue instead to ensure better visibility of your comment. Thank you! |
I also got this error "System.IO.IOException: The process cannot access the file 'C:\MobileApps\app.baf-erp.com\App\Consumer\obj\Debug\net8.0-android\lp\148\jl\classes.jar' because it is being used by another process". This will be fixed if I will build 3 to 4 times. But still, it's frustrating, and feel like whether to switch back to Android Studio. both Xamarin and now MAUI is very slow when you compare other .NET application like Web API etc. Please fix it as just because we love c# and dotnet, we are yet hopeful as one day Microsoft will fix it but it's been almost a year now. |
Description
Getting "process cannot access the file because it is being used by another process" error when building a .NET MAUI App that has a reference to another .NET MAUI App.
Appears to be the same issue as #12653 which was closed due to no activity.
Steps to Reproduce
Expected outcome: The solution successfully builds
Actual outcome: System.IO.IOException: The process cannot access the file 'C:...\obj\Debug\net7.0-android\resizetizer\r\drawable-mdpi\slash.png' because it is being used by another process.
Link to public reproduction project repository
https://github.com/wqotipo5/ResizetizerIssue
Version with bug
7.0 (current)
Last version that worked well
Unknown/Other
Affected platforms
I was not able test on other platforms
Affected platform versions
Windows 10.0.19044
Did you find any workaround?
No response
Relevant log output
No response
The text was updated successfully, but these errors were encountered: