Search Unity

  1. Unity Asset Manager is now available in public beta. Try it out now and join the conversation here in the forums.
    Dismiss Notice

[Bug] Can't save scenes

Discussion in 'Project Tiny' started by Baste, Jul 5, 2019.

  1. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,334
    I'm trying to get to grips with the Tiny, and I'm running into a stumbling block. I can build and run, but whenever I try to save a scene in Tiny, I get an UnauthorizedAccessException:

    Code (csharp):
    1.  
    2. UnauthorizedAccessException: Access to the path "D:\Stuff\workspace\TestTiny\Assets\Samples\Project Tiny\0.15.3-preview\HelloWorld\HelloWorld.project" is denied.
    3. System.IO.FileStream..ctor (System.String path, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share, System.Int32 bufferSize, System.Boolean anonymous, System.IO.FileOptions options) (at <a8ed250850854b439cedc18931a314fe>:0)
    4. System.IO.FileStream..ctor (System.String path, System.IO.FileMode mode, System.IO.FileAccess access, System.IO.FileShare share, System.Int32 bufferSize, System.IO.FileOptions options, System.String msgPath, System.Boolean bFromProxy, System.Boolean useLongPath, System.Boolean checkHost) (at <a8ed250850854b439cedc18931a314fe>:0)
    5. (wrapper remoting-invoke-with-check) System.IO.FileStream..ctor(string,System.IO.FileMode,System.IO.FileAccess,System.IO.FileShare,int,System.IO.FileOptions,string,bool,bool,bool)
    6. System.IO.StreamWriter.CreateFile (System.String path, System.Boolean append, System.Boolean checkHost) (at <a8ed250850854b439cedc18931a314fe>:0)
    7. System.IO.StreamWriter..ctor (System.String path, System.Boolean append, System.Text.Encoding encoding, System.Int32 bufferSize, System.Boolean checkHost) (at <a8ed250850854b439cedc18931a314fe>:0)
    8. System.IO.StreamWriter..ctor (System.String path, System.Boolean append, System.Text.Encoding encoding, System.Int32 bufferSize) (at <a8ed250850854b439cedc18931a314fe>:0)
    9. System.IO.StreamWriter..ctor (System.String path, System.Boolean append, System.Text.Encoding encoding) (at <a8ed250850854b439cedc18931a314fe>:0)
    10. (wrapper remoting-invoke-with-check) System.IO.StreamWriter..ctor(string,bool,System.Text.Encoding)
    11. System.IO.File.WriteAllText (System.String path, System.String contents, System.Text.Encoding encoding) (at <a8ed250850854b439cedc18931a314fe>:0)
    12. System.IO.File.WriteAllText (System.String path, System.String contents) (at <a8ed250850854b439cedc18931a314fe>:0)
    13. Unity.Editor.Extensions.FileInfoExtensions.WriteAllText (System.IO.FileInfo fileInfo, System.String content) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Extensions/FileInfoExtensions.cs:91)
    14. Unity.Editor.Project.Persist (System.IO.FileInfo file, Unity.Editor.Project project) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor/Project.cs:381)
    15. Unity.Editor.Project.SaveAs (System.IO.FileInfo projectFile) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor/Project.cs:349)
    16. Unity.Editor.Project.Save () (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor/Project.cs:332)
    17. Unity.Editor.MenuItems.FileMenuItems.SaveProject () (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Modes/MenuItems/FileMenuItems.cs:91)
    18. Unity.Editor.MenuItems.FileMenuItems.SaveProject (UnityEditor.CommandExecuteContext context) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Modes/MenuItems/FileMenuItems.cs:26)
    19. UnityEditor.CommandService.ExecuteCommand (System.String id, UnityEditor.CommandHint hint, System.Object[] args) (at C:/buildslave/unity/build/Editor/Mono/Commands/CommandService.cs:180)
    20. UnityEditor.CommandService.Execute (System.String id, UnityEditor.CommandHint hint) (at C:/buildslave/unity/build/Editor/Mono/Commands/CommandService.cs:136)
    21. UnityEditor.ModeService+<LoadMenu>c__AnonStorey1.<>m__1 () (at C:/buildslave/unity/build/Editor/Mono/EditorMode/ModeService.cs:383)
    22. UnityEditor.EditorApplication:Internal_CallGlobalEventHandler()
    23.  
    I just followed the instructions in this thread, and I'm using the HelloWorld sample as a building block
    Any advice?
     
  2. bfloyd

    bfloyd

    Joined:
    Dec 6, 2017
    Posts:
    9
    When I created a new project it resolved this error for me (maybe because these are demo projects that we import)