Search Issue Tracker
By Design
Votes
0
Found in
2021.3.47f1
2022.3.56f1
6000.0.33f1
6000.1.0b1
Issue ID
UUM-92394
Regression
No
[Android Module] Unity double writes files in the "StreamingAssets" folder when they are deleted using "IPostGenerateGradleAndroidProject" after the Grandle project is generated
How to reproduce:
1. Open the “ReproStreamingAssets.zip“ project
2. Open the “SampleScene“ scene
3. Build for Android
4. Change the “<name_of_APK>.apk“ extension to “.zip“
5. Extract it and navigate to the “<name_of_APK>/Assets/“
Expected result: The “CompletelyEmptyZIP.zip“ and “GradleDoubleWrite.zip“ files are not present in the Assets folder
Actual result: The “CompletelyEmptyZIP.zip“ and “GradleDoubleWrite.zip“ files are present in the Assets folder
Reproducible with: 2021.3.47f1, 2022.3.56f1, 6000.0.33f1, 6000.1.0b1
Reproducible environment: macOS 15.1.1 (Intel)
Not reproducible environment: No other environment tested
Could not test: Windows 10 Pro (22H2) (Could not find the “zip.jar“ file location)
Note: Adding a breakpoint at the end of the “CustomBuildProcess.cs“ to stop the Editor at that moment, will show that the “CompletelyEmptyZIP.zip“ and “GradleDoubleWrite.zip“ are deleted but then written back
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- VFX Graph particles are not culled when using URP and Frustum Culling is enabled on VFX Mesh Output
- Texture2D hash changes inside of an AssetBundle when rebuilding a SpriteAtlas bundle with an empty AssetPostprocessor Script enabled
- Aniso Level still applies when Generate MipMap is disabled in Texture Import Settings
- Mipmap Limit Groups long names are not truncated when creating a new Mipmap Limit Group with a long name
- “ArgumentException: Invalid double parameter.” error is thrown when Infinity is typed into the Fixed Timestep field
Resolution Note:
There is no sense in deleting or modifying files inside build/intermediates folder. These files are not created by Unity, gradle generates them while building APK or AAB. These files don't even exist when OnPostGenerateGradleAndroidProject is being called and when building for the first time.
StreamingAssets files end up in unityLibrary/src/main/assets folder of the Unity generated gradle project.