Azure / azure-functions-dotnet-worker

Azure Functions out-of-process .NET language worker
MIT License
407 stars 167 forks source link

Publish from Visual Studio 2022 v4 Net7 to linux fail, window fine #1498

Closed imtrobin closed 1 year ago

imtrobin commented 1 year ago

Hi, reporting a new project, V4 Isolated Net 7.

From Visual Studio 2022 17.5.4, publishing to a linux azure function fails with

6>The attempt to publish the ZIP file through https://xx.scm.azurewebsites.net/api/zipdeploy failed with HTTP status code Failed.

Publishing on windows azure function works fine. I know it was like this on V2, but is it still not supported?

fabiocav commented 1 year ago

@imtrobin are you still experiencing this issue?

In order to better assist, it would be helpful to have an application name so we can take a closer look at deployment logs. Is that something you'd be able to share?

Do you have additional information logged about this issue in VS?

Can you also share whether this was on Linux consumption or dedicated/Elastic Premium?

imtrobin commented 1 year ago

Linux comsumption. I updated the app with latest v4 sdk, and I'm able to publish now, so I think we can consider this closed.

imtrobin commented 1 year ago

I spoke too soon. I deleted the one that published fine , recreated a new function linux app, consumption. And the same publishing error. It is same code as the one that published fine.

App name: casstageadmin

Visual studio log 5/4/2023 2:51:09 PM System.AggregateException: One or more errors occurred. ---> Microsoft.WebTools.Shared.Exceptions.WebToolsException: Publish has encountered an error. We were unable to determine the cause of the error. Check the output log for more details. --- End of inner exception stack trace --- ---> (Inner Exception #0) Microsoft.WebTools.Shared.Exceptions.WebToolsException: Publish has encountered an error. We were unable to determine the cause of the error. Check the output log for more details. <---

Microsoft.WebTools.Shared.Exceptions.WebToolsException: Publish has encountered an error. We were unable to determine the cause of the error. Check the output log for more details.

===================

kshyju commented 1 year ago

@imtrobin What version of the worker packages were you using? Would you mind upgrading to the latest packages and see you still experience the issue?

ghost commented 1 year ago

This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment.

oscargscr91 commented 1 year ago

I have same problem here on Zip Deploy for Azure Function from VS2022 17.4.4

System.AggregateException: One or more errors occurred. ---> Microsoft.WebTools.Shared.Exceptions.WebToolsException: Publish has encountered an error. We were unable to determine the cause of the error. Check the output log for more details. --- End of inner exception stack trace --- ---> (Inner Exception #0) Microsoft.WebTools.Shared.Exceptions.WebToolsException: Publish has encountered an error. We were unable to determine the cause of the error. Check the output log for more details.

I am trying to Publish Azure Function v4 .NET 6 on Linux with Microsoft.NET.Sdk.Functions 4.2.0 but the error ocurred

Publishing \obj\Release\net6.0\PubTmp\fxName - 20230620211127488.zip to https://subdomain.scm.azurewebsites.net/api/zipdeploy... 4>Zip Deployment failed.

Neutrino-Sunset commented 1 year ago

I'm getting this too. Just updated Visual Studio from 17.5.6 to 17.6.5 and now I can't publish any Linux Function App at all.

oscargscr91 commented 1 year ago

I resolved my problem with 2 actions: