Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Publishing Azure Website fails #693

Closed
cwoolum opened this issue Oct 29, 2015 · 19 comments
Closed

Publishing Azure Website fails #693

cwoolum opened this issue Oct 29, 2015 · 19 comments
Assignees

Comments

@cwoolum
Copy link
Contributor

cwoolum commented Oct 29, 2015

When trying to deploy an Azure website, i am getting an exception that the site is already created and cannot be created again. This deploy process was working until October 23rd. Did anything change in the deploy script? I think it thinks the site doesn't exist and tries to create it again.

2015-10-29T03:19:24.6803000Z Get-AzureWebSite -Name WaxonService -ErrorAction SilentlyContinue

2015-10-29T03:19:31.7421204Z New-AzureWebSite -Name WaxonService -Location South Central US

2015-10-29T03:19:34.9330598Z ##[error]Conflict: Website with given name WaxonService already exists.

2015-10-29T03:19:34.9350596Z Publish-AzureWebsiteProject -Name "WaxonService" -Package "C:\a\1\a\Waxon.Service.zip" 

2015-10-29T03:19:51.0621612Z Finishing task: AzureWebPowerShellDeployment
@bryanmacfarlane
Copy link
Contributor

assigning to yaswanth to investigate

@yaananth
Copy link
Member

@cwoolum There has been no changes in the way the script runs.
It is quite possible that Get-AzureWebsite returns some error while retrieving the website and since we silently eat up the error there is no way for us to know.
However, this will change in M90 deployment, as we capture the error and print it out as a warning.
Could you try the command - Get-AzureWebSite -Name WaxonService on azure powershell commandprompt and see if it throws out some error?

Last time we saw this, it was because the website has VS2015 debugging mode on, I am not sure if that's fixed yet, but the workaround was to turn it off and use VS2013 instead at that moment,

@cwoolum
Copy link
Contributor Author

cwoolum commented Oct 29, 2015

Debugging was not enabled but when I had used it previously, it was set as 2015.

To Fix:

  1. Enable Debugging and set version to 2013
  2. Save changes
  3. Disable debugging and Save Changes

Go figure... haha

@cwoolum cwoolum closed this as completed Oct 29, 2015
@ianschmitz
Copy link

This issue still exists. Maybe it should be re-opened?

When I was trying to publish from VSO after using remote debugging, i got the error in the VSO build console:

2015-11-09T22:51:58.9878309Z ##[warning]System.ArgumentException: Requested value 'VS2015' was not found.
2015-11-09T22:51:58.9888361Z ##[warning]   at Microsoft.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
2015-11-09T22:51:58.9898314Z ##[warning]   at Microsoft.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccess(Task task)
2015-11-09T22:51:58.9898314Z ##[warning]   at Microsoft.WindowsAzure.Management.WebSites.WebSiteOperationsExtensions.GetConfiguration(IWebSiteOperations operations, String webSpaceName, String webSiteName)
2015-11-09T22:51:58.9908303Z ##[warning]   at Microsoft.WindowsAzure.Commands.Utilities.Websites.WebsitesClient.GetWebsiteConfiguration(String name)
2015-11-09T22:51:58.9908303Z ##[warning]   at Microsoft.WindowsAzure.Commands.Websites.GetAzureWebsiteCommand.WriteWebsite(Site websiteObject)
2015-11-09T22:51:58.9918302Z ##[warning]   at Microsoft.WindowsAzure.Commands.Websites.GetAzureWebsiteCommand.<GetByName>b__0()
2015-11-09T22:51:58.9928294Z ##[warning]   at Microsoft.WindowsAzure.Commands.Websites.GetAzureWebsiteCommand.Do(Action call)
2015-11-09T22:51:58.9928294Z ##[warning]   at Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet.ProcessRecord()
2015-11-09T22:51:58.9948296Z New-AzureWebSite -Name fakesite -Location West US
2015-11-09T22:52:01.7199514Z ##[error]Conflict: Website with given name fakesite already exists.

The only way i could fix it was to change the Remote Visual Studio version inside of the Azure Portal to 2013 instead of 2015. Not sure on the implications of changing this but I was able to publish in the mean time.

@cwoolum
Copy link
Contributor Author

cwoolum commented Nov 10, 2015

It's not a VSO issue... It's a problem with the Powershell Command Get-AzureWebSite. Not sure who handles that....

@ramedey
Copy link

ramedey commented Feb 10, 2016

Today I've experienced the same issue. If it is not a VSO issue, where can I report it?

@yaananth
Copy link
Member

Probably here - https://github.com/Azure/azure-powershell

@ramedey
Copy link

ramedey commented Feb 10, 2016

Thanks

@yaananth
Copy link
Member

Infact there is an active issue Azure/azure-powershell#462

@mxa0079
Copy link

mxa0079 commented Mar 14, 2016

It looks like there is a fix coming based on the conversation referenced by @yaananth Could we reopen this issue to track it until the fix makes it to production?

@kpgeek
Copy link

kpgeek commented Apr 8, 2016

I got the similar issue. I tried to implement the steps as suggested by
@cwoolum. No luck :( I am getting the same error.

Detail Error:
**Get-AzureWebSite -Name dummy123 -ErrorAction SilentlyContinue -ErrorVariable azureWebSiteError -Slot production
**[warning]System.ArgumentException: Requested value 'Dynamic' was not found.
[warning] at Microsoft.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
[warning] at Microsoft.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccess(Task task)
[warning] at Microsoft.WindowsAzure.Management.WebSites.WebSpaceOperationsExtensions.ListWebSites(IWebSpaceOperations operations, String webSpaceName, WebSiteListParameters parameters)
[warning] at Microsoft.WindowsAzure.Commands.Utilities.Websites.Services.WebSitesManagementExtensionMethods.GetFromAzure(IWebSiteManagementClient client, String website)
[warning] at Microsoft.WindowsAzure.Commands.Utilities.Websites.WebsitesClient.GetWebsite(String name)
[warning] at Microsoft.WindowsAzure.Commands.Utilities.Websites.WebsitesClient.GetWebsiteConfiguration(String name)
[warning] at Microsoft.WindowsAzure.Commands.Websites.GetAzureWebsiteCommand.WriteWebsite(Site websiteObject)
[warning] at Microsoft.WindowsAzure.Commands.Websites.GetAzureWebsiteCommand.b__0()
[warning] at Microsoft.WindowsAzure.Commands.Websites.GetAzureWebsiteCommand.Do(Action call)
[warning] at Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet.ProcessRecord()
New-AzureWebSite -Name dummy123 -Location West US -Slot production
Conflict: Website with given name dummy123 already exists.

Publish-AzureWebsiteProject -Name "dummy123" -Package "C:\a\00b3423458\dummy123\drop\dummy123.zip" -Slot "production" -ErrorVariable publishAzureWebsiteError
[warning]Cannot get website, deployment status is not updated

Steps followed:

1. Enabled remote debugging ON, Set VS Version to 2013 and saved the changes

image

2. Disabled remote debugging OFF and saved the changes. Now, I see VS Version 2013

image

  1. After both steps, I tried to redeploy website. Its giving the same error. I am wondering why Get-AzureWebsite command is unable to recognize whether webapp is existed or not in the portal. Why New-AzureWebSite -Name command is adding in the script? Can we customize the "Azure web deployment task" ps script?

*I would really appreciate if any solution / workaround for this issue. *

@RoopeshNair
Copy link
Member

@kpgeek

Based on the update here https://connect.microsoft.com/VisualStudio/feedback/details/2559822/-error-requested-value-dynamic-was-not-found

Removing Azure Functions solves the problem

@PirateBread
Copy link

PirateBread commented Nov 24, 2016

Haha this is hilarious. Adding a functions app to your subscription breaks the AzureWebsite command.

So you add a function on a test resource group to play around with things and suddenly your production deployments are breaking because the AzureWebsite command starts throwing errors.

@ddobric
Copy link

ddobric commented Dec 22, 2016

Hi all,

I have same issue when creating a new fresh website. Is this fixed? Is this production ready?
After some investigation, I figured out, the creating a site in a new resource group solves the problem.
It looks as some previously created resources in the RG prevents deployment of new web site.
I have tried both, incremental and complete deployment.
After I created a new RG multiple deployments worked well.

My recommendation would be to first provide a correct error message. Unfortunately, strange error messages might be a typical ARM issue, which should be fixed by ARM team :)

But, deployment in VS-online has definitely an issue with existing resource in the group.

@mohdumairakbar
Copy link

Hi All,

I am facing the same issue "Requested value 'Dynamic' was not found." while running New-AzureWebsiteJob on build definition through powershell script.

This was working fine few days back. I got this error and now stuck on it.

Any help. Highly Appreciated.

Thanks
Umair

@ryanbennett
Copy link

I received the same error after creating an Azure Function and trying to deploy my website.

@mohdumairakbar
Copy link

Installing the latest version of Powershell through web platfrom installer worked for me.

Make sure you restart your machine after installing latest powershell else you will face error "he required module 'Azure.Storage' is not loaded"

@ryanbennett
Copy link

Deleting the Azure function from my App Services screen let me continue building. Thankfully I was just testing the Function capabilities and not using it for anything

@leelep
Copy link

leelep commented Mar 6, 2019

I experienced the same issue using the new DevOps web site, and it was due to being logged in to DevOps with the wrong account. The DevOps site doesn't seem to recognize the difference between work and personal accounts of the same email address. The Get-AzureWebSites PowerShell command does distinguish between the two. If you have multiple accounts and experience the described issue then double check that you are signed in to DevOps with an account that has permissions for the Azure web site.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests