googlesamples / unity-jar-resolver

Unity plugin which resolves Android & iOS dependencies and performs version management
Other
1.24k stars 339 forks source link

[Bug] GvhProjectSettings.xml changes/resets itself #524

Closed ManuelRauber closed 3 months ago

ManuelRauber commented 2 years ago

[REQUIRED] Please fill in the following fields:

[REQUIRED] Please describe the issue here:

Sometimes, not really reproducible, the file GvhProjectSettings.xml changes/resets itself. This is super annoying, because the file pops up in the git stage:

image

As well as this dialogs pops up all the time

image

And as you can see from the diff file above, the settings get reset, e.g. I've disabled both auto-resolution on build and in editor and it will reset back to true, because that's the default.

I currently can not reproduce it exactly, when it happens. Sometimes it does not happen all day, sometimes it happens multiple times day.

mhctseu commented 8 months ago

Sorry for long delay since last update. Here is new attempt. This time I'm avoiding overriding the file when settings didn't change. Previously, even when settings are the same, the file gets written 3 times with every domain reload. I added an extra check to skip file write if settings didn't change since last read.

I'm opening the pull request again as well.

Again, your feedback is appreciated.

@AliAlbarrak Salute!

Feel so sad that the team ignored your work and no feedback at all.

Ned11 commented 8 months ago

This issue is observed in 1.2.177 and 1.2.178. I am surprised that there's no official fix for an issue that started two years ago.

RocksteadyDog commented 8 months ago

I tried version 1.2.180 and so far everything is great!)

Tommigun1980 commented 7 months ago

@AliAlbarrak Thanks so much for the pull request. I tried your version but unfortunately there's still some issues. In my setup I have copied the .tgz file to the packages folder and selected "install from package" (so the manifest points to the local package path and the .tgz file is committed to source control).

The issues are as follows:

If you have time to fix these issues, or if anyone else could build on the pull request that would be great, as I'm worried the pull request will otherwise be rejected as it doesn't fully solve the issue.

Thanks so much again for your tremendous effort, I appreciate it a lot!

Tommigun1980 commented 7 months ago

@paulinon Please can't anyone from Google support us? The resolver has been quite broken for years and we are really scrambling to make this work. At this point any support for your software would be appreciated and would be in your interest as well, as the resolver makes sure software is released on Android platforms as well. Thank you.

AliAlbarrak commented 7 months ago

@Tommigun1980 Thanks for your report. My team use a similar deployment (using .tgz file) but I couldn't reproduce your issues. It is understandable since this bug is very inconsistent but if you can provide more info about how to reproduce your issues, or a minimal sample project, I'll gladly try to fix them

Tommigun1980 commented 7 months ago

@Tommigun1980 Thanks for your report. My team use a similar deployment (using .tgz file) but I couldn't reproduce your issues. It is understandable since this bug is very inconsistent but if you can provide more info about how to reproduce your issues, or a minimal sample project, I'll gladly try to fix them

Hi and thanks again for your effort with the patch. I don't have repro steps other than opening the project and the resolver pops up. Don't think I saw any difference vs the official version fwiw. I am using an Intel MacBook Pro (2019), macOS Ventura and Unity 2022.3.15.

berniegp commented 6 months ago

New fix attempt in #678 with an analysis of why this issue happens. Binaries here https://github.com/berniegp/unity-jar-resolver/releases/tag/v1.2.179 for those who want to try it out.

harlan commented 5 months ago

What are the steps to try to get @berniegp 's #678 tested/merged etc?

berniegp commented 5 months ago

Update: 1 month in at my org we're not seeing setting file corruption anymore on Windows and MacOS.

jonsenson-uken commented 3 months ago

Just a heads up, we tried @berniegp's fix recently and the binaries provided ended up breaking our iOS builds on Jenkins. We're currently on Unity 2022.3.22 and XCode 15.0.1 and for some reason using these updated binaries causes the resolver to never apply its postbuild processing and the Podfile is never generated which broke our Firebase dependency.

Not entirely sure what the issue was since I see no obvious errors in the logs. It just seemed to ignore the settings file and never generate the Podfile. Reverting only the iOSResolver.dll to the non-patched version fixes the issue so we're hoping that doing only that will fix the settings file being reset in editor while allowing builds to complete.

a-maurice commented 3 months ago

I've done a release with the fix, version 1.2.180. @jonsenson-uken I'm not sure what the issue you saw could be, I tried a couple different Unity versions to test, and it seemed good on my end. But if you are still having issues, please open a new issue ticket about it, along with anything that might help ping down a problem.

CodeMasterYi commented 3 months ago

Wow! Finally!

jonsenson-uken commented 3 months ago

@a-maurice We've updated to 1.2.180 and the Podfile issue doesn't appear to be present on that version. Thanks a lot for the release!

calumma-robert commented 3 months ago

That are great news! Thanks!

CodeMasterYi commented 3 months ago

Great NEWS!