Search Issue Tracker
Fixed
Fixed in 5.6.X
Votes
0
Found in
5.4.4p1
Issue ID
898217
Regression
No
[macOS] Application.persistentDataPath returns Library/Caches instead of Library/ApplicationSupport when cache folder is present
When cache folder is available, Application.persistentDataPath incorrectly returns its location instead of Library/ApplicationSupport.
Steps to reproduce:
1) Open the latest attached project (898217_macOSDataPath.zip).
2) Assets > Build AssetBundles.
3) Build the project for macOS.
4) Run the build.
- Application.persistentDataPath is printed on the screen. Notice that it points to ~/Library/ApplicationSupport/<companyName>/<productName>
5) Press 'Load AssetBundle' button.
- After a couple seconds, a sphere appears in the scene. Cache folder is generated in ~/Library/Caches/.
- Now Application.persistentDataPath points to ~/Library/Caches/unity.<companyName>.<productName>
6) Press 'Delete Cache' button.
- The cache folder is deleted.
- Application.persistentDataPath points to Library/ApplicationSupport again.
Expected: Application.persistentDataPath always points to Library/ApplicationSupport.
Actual: Application.persistentDataPath points to Library/Caches when there is a cache folder available.
This does not reproduce on Windows.
Reproduced on:
2017.1.0a6, 5.4.5p1, 5.3.8f1
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Shader Graph Asset icon is not shown on creation unless you confirm the name
- APV Sky occlusion doesn't consider the terrain
- [iOS] "EXC_BAD_ACCESS" Player crash when Script Debugging is enabled
- Cursor skips input fields when tabbing between two sets of input fields
- "Shader error redefinition of 'Varyings'" error appears when selecting the shader
Add comment