Search Unity

UnauthorizedAccessException when using Unity Perforce integration

Discussion in 'Addressables' started by stefankohl, Jun 20, 2019.

  1. stefankohl

    stefankohl

    Joined:
    May 30, 2014
    Posts:
    53
    When using Unity's Perforce VCS integration, AAS fails to update addressables_content_state.bin when building player content due to the file being readonly. This causes an UnauthorizedAccessException exception to rise:


    In Perforce, you have to manually check out assets prior to editing them in order to make them writable. Checking out addressables_content_state.bin helps to fix this issue. Unity usually does this for you automatically if you are indirectly editing an asset (e.g., by updating project settings or saving scene changes) as opposed to direct asset editing using the inspector. Therefore, the expected behaviour would be the AAS checking out addressables_content_state automatically before updating if Perforce integration is active. Please consider adding this feature in future updates!
     
  2. unity_bill

    unity_bill

    Joined:
    Apr 11, 2017
    Posts:
    1,053
    Definitely, thanks for the suggestion.
     
    stefankohl likes this.
  3. rtm223

    rtm223

    Joined:
    Apr 12, 2017
    Posts:
    28
    This is still occurring with the 1.5.1 release of addressables. Is there an ETA on this fix?
     
    twhittaker likes this.
  4. conondev

    conondev

    Joined:
    Jun 9, 2016
    Posts:
    24
    I don't know but I also encounter this issue with git on my CI/CD build.
    How would I fix this with gitlab CI/CD process?
     
  5. conondev

    conondev

    Joined:
    Jun 9, 2016
    Posts:
    24
    Oh never mind, it's my fault. I used wrong path for the addressables_content_state.bin file.