locked
ToggleDebugCompilation fails trying to perform "an unauthorised operation" RRS feed

  • Question

  • User753017102 posted

    Hi,

    We're having a problem with the Visual Studio 2008 RTW version of the web deployment projects on a colleagues machine. The project works fine if I run it on my machine, but when he tries to run it on his machine he gets:

    <SNIP : Most output removed>
      Task "Exec"
        Command:
        if exist ".\TempBuildDir\" rd /s /q ".\TempBuildDir\"
      Done executing task "Exec".
      Using "ToggleDebugCompilation" task from assembly "C:\Program Files\MSBuild\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.Tasks.dll".
      Task "ToggleDebugCompilation"
        Updating Web.config <compilation> element debug attribute to 'True'.
        C:\Program Files\MSBuild\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.targets(639,7): error : Attempted to perform an unauthorized operation.
        C:\Program Files\MSBuild\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.targets(639,7): error MSB4018: The "ToggleDebugCompilation" task failed unexpectedly.
        C:\Program Files\MSBuild\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.targets(639,7): error MSB4018: System.ArgumentNullException: Parameter "message" cannot be null.
        C:\Program Files\MSBuild\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.targets(639,7): error MSB4018:    at Microsoft.Build.Shared.ErrorUtilities.VerifyThrowArgumentNull(Object parameter, String parameterName, String resourceName)
        C:\Program Files\MSBuild\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.targets(639,7): error MSB4018:    at Microsoft.Build.Utilities.TaskLoggingHelper.LogMessage(MessageImportance importance, String message, Object[] messageArgs)
        C:\Program Files\MSBuild\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.targets(639,7): error MSB4018:    at Microsoft.WebDeployment.Tasks.ToggleDebugCompilation.Execute()
        C:\Program Files\MSBuild\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.targets(639,7): error MSB4018:    at Microsoft.Build.BuildEngine.TaskEngine.ExecuteInstantiatedTask(EngineProxy engineProxy, ItemBucket bucket, TaskExecutionMode howToExecuteTask, ITask task, Boolean& taskResult)
      Done executing task "ToggleDebugCompilation" -- FAILED.
    Done building target "CopyToOutputDir" in project "Debug Server.wdproj" -- FAILED.
    
    Done building project "Debug Server.wdproj" -- FAILED.

    The above is with the MSBuild output level set to diagnostic. As far as I can see, it's failing due to some error while trying to modify the web.config file but it doesn't give any more details than that.

    If it helps, the project is set to deploy to a shared network folder that we have identical permissions to.

    Any thoughts?

    Thursday, June 10, 2010 10:23 AM

Answers