Azure-functions-host: A command that prompts the user failed

Created on 9 Nov 2016  路  4Comments  路  Source: Azure/azure-functions-host

Ported from: https://github.com/Azure/Azure-Functions/issues/53

@ariel1974 asked:

When I'm trying to delete a file from a File storage account I'm getting this:

Exception while executing function: Functions.TimerTriggerPowerShell1. Microsoft.Azure.WebJobs.Script: PowerShell script error. System.Management.Automation: A command that prompts the user failed because the host program or the command type does not support user interaction. The host was attempting to request confirmation with the following message: Are you sure you want to perform this action?
Performing the operation "Remove-AzureStorageFile" on target "drawings/7.filtered.json".

Any idea what I'm missing?

lang-PowerShell question

Most helpful comment

Try adding -Confirm:$false or -Force to the end of the command.

All 4 comments

Hey @tohling, do you know how to write scripts that call commands that show prompts? Is there some way to suppress the prompt?

Try adding -Confirm:$false or -Force to the end of the command.

thank you very much @tohling , i'll try that and let you know. The weird part with this issue though, it doesn't happened in other storage account i've got, and the same script successfully deletes all files there.

Did that work?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

rati3l picture rati3l  路  3Comments

alaatm picture alaatm  路  4Comments

silencev picture silencev  路  4Comments

helgemahrt picture helgemahrt  路  4Comments

svickers picture svickers  路  3Comments