1. Step to reproduce:

    1. Work with any csharp plugin.
    2. Save file so server will going recompile file.
    3. If compilation time is big (1 second for example) and resave file before it finish compilation will be error.
    4. After this i can't anymore reload or load this plugin without server restart.

    Happens sometimes when i'm doing some fast-edits just after save files. Its annoying.
    Code:
    [3/21/2015 11:35:09 PM] [Oxide] 11:35 PM [Info] Test plugin was compiled successfully in 1180ms
    [3/21/2015 11:35:09 PM] [Oxide] 11:35 PM [Info] Unloaded plugin Test v0.0.1 by AlexALX
    [3/21/2015 11:35:09 PM] [Oxide] 11:35 PM [Info] Loaded plugin Test v0.0.1 by AlexALX
    [3/21/2015 11:36:17 PM] [Oxide] 11:36 PM [Info] Unloaded plugin Test v0.0.1 by AlexALX
    [3/21/2015 11:36:17 PM] [Oxide] 11:36 PM [Info] Exception while patching Test assembly: System.IO.FileNotFoundException: Could not find file "Z:\home\***\rust\server_test\server\***\oxide\temp\Test_366.dll".
    File name: 'Z:\home\***\rust\server_test\server\***\oxide\temp\Test_366.dll'
      at System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean anonymous, FileOptions options) [0x00000] in <filename unknown>:0
      at System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access, FileShare share) [0x00000] in <filename unknown>:0
      at (wrapper remoting-invoke-with-check) System.IO.FileStream:.ctor (string,System.IO.FileMode,System.IO.FileAccess,System.IO.FileShare)
      at Mono.Cecil.ModuleDefinition.GetFileStream (System.String fileName, FileMode mode, FileAccess access, FileShare share) [0x00000] in <filename unknown>:0
      at Mono.Cecil.ModuleDefinition.ReadModule (System.String fileName, Mono.Cecil.ReaderParameters parameters) [0x00000] in <filename unknown>:0
      at Mono.Cecil.ModuleDefinition.ReadModule (System.String fileName) [0x00000] in <filename unknown>:0
      at Mono.Cecil.AssemblyDefinition.ReadAssembly (System.String fileName) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.CompilablePlugin+<PatchAssembly>c__AnonStorey2.<>m__0 (System.Object _) [0x00000] in <filename unknown>:0
    [3/21/2015 11:36:18 PM] [Oxide] 11:36 PM [Info] Test plugin was compiled successfully in 1172ms
    [3/21/2015 11:36:18 PM] [Oxide] 11:36 PM [Info] Plugin is already being loaded: Test
    [3/21/2015 11:36:33 PM] [Oxide] 11:36 PM [Info] Plugin is already being loaded: Test
     
    Last edited by a moderator: Mar 22, 2015
  2. Please update to the latest snapshot. I reworked plugin compilation a day ago to solve a few rare edge case issues. This issue cannot occur now that assemblies are patched from memory.
     
  3. Thank you, now no this error anymore and it seems like temp folder also not used anymore.
     
  4. Did you find a solution to this without restarting? I'm having the same issue.
     
  5. Wulf

    Wulf Community Admin

    oxide.reload pluginname
     
  6. I'm getting [Debug] Reload requested for plugin which is already being reloading: StackSizes

    It's been "reloading" for hours now. Restarting the server works, but I'm trying not to drive my players away if I can help it
     
  7. Wulf

    Wulf Community Admin

    It's likely loading a previously compiled version on restart. Do you have any errors in your oxide/logs/compiler files?