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

Extensions.Storage 3.0.0 & WindowsAzure.Storage 9.3.2 fails to bind to CloudQueueMessage #3784

Closed
HiroyukiSakoh opened this issue Oct 3, 2018 · 29 comments
Assignees
Labels

Comments

@HiroyukiSakoh
Copy link

I'm using function runtime version 2.0.12115.0 .
Extensions.Storage 3.0.0 & WindowsAzure.Storage 9.3.2 fails to bind to CloudQueueMessage.

  • Message
Exception while executing function: Function1 Exception binding parameter 'myQueueItem' String reference not set to an instance of a String.
 Parameter name: s

Why does this error happen?
When using Extensions.Storage 3.0.0, do I have to always use WindowsAzure.Storage 9.3.1?

  • failure
Microsoft.Azure.WebJobs.Extensions.Storage 3.0.0
WindowsAzure.Storage 9.3.2
public static void Run([QueueTrigger("myqueue-items", Connection = "StorageConnectionString")]CloudQueueMessage myQueueItem, ILogger log)
{
    log.LogInformation($"C# Queue trigger function processed: {myQueueItem}");
}
  • success1
Microsoft.Azure.WebJobs.Extensions.Storage 3.0.0
WindowsAzure.Storage 9.3.1
public static void Run([QueueTrigger("myqueue-items", Connection = "StorageConnectionString")]CloudQueueMessage myQueueItem, ILogger log)
{
    log.LogInformation($"C# Queue trigger function processed: {myQueueItem}");
}
  • success2
Microsoft.Azure.WebJobs.Extensions.Storage 3.0.0
WindowsAzure.Storage 9.3.2
public static void Run([QueueTrigger("myqueue-items", Connection = "StorageConnectionString")]string myQueueItem, ILogger log)
{
    log.LogInformation($"C# Queue trigger function processed: {myQueueItem}");
}
  • StackTrace
Microsoft.Azure.WebJobs.Host.FunctionInvocationException:
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor+<ExecuteWithLoggingAsync>d__17.MoveNext (Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Executors\FunctionExecutor.csMicrosoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: 293)
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor+<TryExecuteAsync>d__14.MoveNext (Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Executors\FunctionExecutor.csMicrosoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: 89)
Inner exception System.InvalidOperationException handled at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw:
   at Microsoft.Azure.WebJobs.Host.Executors.DelayedException.Throw (Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Executors\DelayedException.csMicrosoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: 27)
   at Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor+<ExecuteWithWatchersAsync>d__24.MoveNext (Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Executors\FunctionExecutor.csMicrosoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: 478)
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor+<ExecuteWithLoggingAsync>d__23.MoveNext (Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Executors\FunctionExecutor.csMicrosoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: 444)
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at Microsoft.Azure.WebJobs.Host.Executors.FunctionExecutor+<ExecuteWithLoggingAsync>d__17.MoveNext (Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Executors\FunctionExecutor.csMicrosoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: 249)
Inner exception System.ArgumentNullException handled at Microsoft.Azure.WebJobs.Host.Executors.DelayedException.Throw:
   at System.Text.Encoding.GetBytes (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at Microsoft.WindowsAzure.Storage.Queue.CloudQueueMessage.get_AsBytes (Microsoft.WindowsAzure.Storage, Version=9.3.2.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35)
   at Microsoft.Azure.WebJobs.Host.PropertyHelper.CallPropertyGetter (Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\PropertyHelper.csMicrosoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: 354)
   at Microsoft.Azure.WebJobs.Host.PropertyHelper.GetValue (Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\PropertyHelper.csMicrosoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: 97)
   at Microsoft.Azure.WebJobs.Host.Bindings.BindingDataProvider.GetBindingData (Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Bindings\BindingDataProvider.csMicrosoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: 70)
   at Microsoft.Azure.WebJobs.Host.Queues.Triggers.UserTypeArgumentBindingProvider+UserTypeArgumentBinding.BindAsync (Microsoft.Azure.WebJobs.Extensions.Storage, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35Microsoft.Azure.WebJobs.Extensions.Storage, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Extensions.Storage\Queues\Triggers\UserTypeArgumentBindingProvider.csMicrosoft.Azure.WebJobs.Extensions.Storage, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: 72)
   at Microsoft.Azure.WebJobs.Host.Queues.Triggers.QueueTriggerBinding+<BindAsync>d__19.MoveNext (Microsoft.Azure.WebJobs.Extensions.Storage, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35Microsoft.Azure.WebJobs.Extensions.Storage, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Extensions.Storage\Queues\Triggers\QueueTriggerBinding.csMicrosoft.Azure.WebJobs.Extensions.Storage, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: 111)
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult (System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e)
   at Microsoft.Azure.WebJobs.Host.Triggers.TriggeredFunctionBinding`1+<BindCoreAsync>d__8.MoveNext (Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35Microsoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Triggers\TriggeredFunctionBinding.csMicrosoft.Azure.WebJobs.Host, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35: 57)
@grahamehorner
Copy link

@HiroyukiSakoh I've also seen this issue, unfortunately I had to regress the WindowsAzure Storage nuget to the same version used by the Functions SDK in a number of our components to allow us to move forward; the exception I've seen is coming from deep within the code when attempting to de-serialize the message.

@grahamehorner
Copy link

@paulbatum
Copy link
Member

paulbatum commented Oct 29, 2018

@fabiocav I can confirm a repro. In VS just make a queue triggered function, change the param type, then update from 9.3.1 to 9.3.2 and you'll hit it. This is a bug, we need to investigate.

@fabiocav
Copy link
Member

This is indeed a defect and not the expected behavior. We'll have this addressed and use this issue to track the work/fix.

@fabiocav fabiocav transferred this issue from Azure/azure-webjobs-sdk Nov 15, 2018
@fabiocav fabiocav self-assigned this Nov 15, 2018
@fabiocav fabiocav added this to the Triaged milestone Nov 15, 2018
@cbfrank
Copy link

cbfrank commented Nov 22, 2018

accroding to the document https://docs.microsoft.com/en-us/azure/cosmos-db/table-storage-how-to-use-dotnet, there is a tip:

Developers already familiar with Azure Table storage may have used the WindowsAzure.Storage package in the past. It is recommended that all new table applications use the Azure Storage Common Library and the Azure Cosmos DB Table Library, however the WindowsAzure.Storage package is still supported. If you use the WindowsAzure.Storage library, include Microsoft.WindowsAzure.Storage.Table in your using statements.

It seems Microsoft.Azure.WebJobs.Host.Storage(3.0.0) still use WindowsAzure.Storage not the Microsoft.Azure.Storage.Common package.

@guru98
Copy link

guru98 commented Jan 30, 2019

with 3.0.3 and 9.3.3 the issue is still there. Any clue when it will be fixed?

@StephenCleary
Copy link

StephenCleary commented Mar 19, 2019

For Googleability, I ran into this issue when I had an Http trigger that writes to a queue using IAsyncCollector<CloudQueueMessage> (with a manually serialized message string), and then a queue trigger off that which is bound to a string.

The current Microsoft.Azure.WebJobs.Extensions.Storage 3.0.4 depends on WindowsAzure.Storage (>= 9.3.1), but WindowsAzure.Storage 9.3.2 and 9.3.3 break. The behavior I see is that the message on the queue (that my queue trigger function reads as a string) is actually a JSON object with asBytes and asString properties, with my serialized message model object actually in the asString property. Example message:

{
  "asBytes": "eyJ2ZXJzaW9uIjowLCJqc29uVmVyc2lvbiI6MCwibm9ybWFsaXplZFBhY2thZ2VJZCI6Im5pdG8uYXN5bmNleCIsIm5vcm1hbGl6ZWRQYWNrYWdlVmVyc2lvbiI6IjQuMC4xIiwibm9ybWFsaXplZEZyYW1ld29ya1RhcmdldCI6Im5ldDQ1Iiwib3BlcmF0aW9uSWQiOiI0MGMyM2IxMy0yYzU1LTRiN2MtYmYwNC04MDUzNTNmZDZlYjciLCJwYXJlbnRPcGVyYXRpb25JZCI6IjAwMDAwMDAwLTAwMDAtMDAwMC0wMDAwLTAwMDAwMDAwMDAwMCJ9",
  "asString": "{\"version\":0,\"jsonVersion\":0,\"normalizedPackageId\":\"nito.asyncex\",\"normalizedPackageVersion\":\"4.0.1\",\"normalizedFrameworkTarget\":\"net45\",\"operationId\":\"40c23b13-2c55-4b7c-bf04-805353fd6eb7\",\"parentOperationId\":\"00000000-0000-0000-0000-000000000000\"}",
  "dequeueCount": 0,
  "$AzureWebJobsParentId": "40c23b13-2c55-4b7c-bf04-805353fd6eb7"
}

This was observed using Azure Functions Core Tools (2.4.432 Commit hash: 3371a87e0fce2aa35986c0de8e77d5d618163b91) and Function Runtime Version: 2.0.12332.0, running locally.

@fabiocav fabiocav modified the milestones: Triaged, Functions Sprint 49 Apr 23, 2019
@fabiocav fabiocav removed their assignment Apr 23, 2019
@fabiocav fabiocav added 1.x bug and removed 1.x labels Apr 23, 2019
@fabiocav fabiocav self-assigned this May 1, 2019
@fabiocav
Copy link
Member

fabiocav commented May 15, 2019

Small update on this.

We're working on addressing the issue, but in the meantime, a mitigation option is to add the following to your project file (this will also be automatically handled by tooling):

  <Target Name="PostBuild" AfterTargets="PostBuildEvent">
    <Exec Command="copy $(OutDir)$(ProjectName).deps.json $(OutDir)bin\function.deps.json" />
  </Target>
  <Target Name="PostPublish" AfterTargets="AfterPublish">
    <Exec Command="copy $(PublishDir)$(ProjectName).deps.json $(PublishDir)bin\function.deps.json" />
  </Target>

Will keep this issue open until completely resolved, but the above should unblock the scenario.

@valdisiljuconoks
Copy link

can confirm that this workaround is working for now..

@ttalwar1
Copy link

question for Fabio's workaround: any ETA on a fix? Also can you please explain where the above goes in the project file? Is this the function that is triggered by the queue? We're working on a customer demo for Function/Queues and this is blocking....thank you.

@jasoncoding
Copy link

Still an issue with 3.0.6 and 9.3.1. After a build the Microsoft.WindowsAzure.Storage.dll file on disk in bin\Debug\netcoreapp2.2\bin says 9.3.1

For me the workaround isn't - same error. My workaround was to let it deserialize my json (what's in the queue message) to a poco. But that's suboptimal since I wish to log the contents of the raw CloudQueueMessage.

Any clue when it will be fixed?

@fabiocav
Copy link
Member

fabiocav commented Jul 2, 2019

@jasoncoding Can you please open a separate issue, include the details of what you're seeing and perhaps a repro. Based on what you're describing, you're dealing with something different than what is tracked by this issue.

@fabiocav
Copy link
Member

fabiocav commented Jul 2, 2019

Linking to the SDK issue tracking the work needed to complete this
Azure/azure-functions-vs-build-sdk#271

@jasoncoding
Copy link

@fabiocav The details of what I'm seeing are the exact details in this issue.

Exception while executing function: Exception binding parameter 'msg' String reference not set to an instance of a String. Parameter name: s

I didn't play around with every combination of Extensions.Storage and WindowsAzure.Storage so I can't comment on the precise cause but I experience the exact same effect described in this thread. If I get time I shall post a repro.

@fabiocav
Copy link
Member

fabiocav commented Jul 2, 2019

@jasoncoding what you’ve stated above describes a different issue than what is described in the original issue. The fact that you’re experiencing issues with the.version that works for others, and the workaround doesn’t help, indicates that you have a different problem. The way this is manifested and the exception message may be the same, but it’s unlikely it has the same root cause. A separate issue, with details similar to what the original author provided, with a repro, would Help us identify the problem and better assist you.

@MisinformedDNA
Copy link

MisinformedDNA commented Jul 15, 2019

@fabiocav

What task and settings would you use for this in Azure DevOps?

  <Target Name="PostBuild" AfterTargets="PostBuildEvent">
    <Exec Command="copy $(OutDir)$(ProjectName).deps.json $(OutDir)bin\function.deps.json" />
  </Target>
  <Target Name="PostPublish" AfterTargets="AfterPublish">
    <Exec Command="copy $(PublishDir)$(ProjectName).deps.json $(PublishDir)bin\function.deps.json" />
  </Target>

I was building with the Visual Studio build task (YAML below) in Azure DevOps and the function.deps.json doesn't get copied.

steps:
- task: VSBuild@1
  displayName: 'Build solution'
  inputs:
    solution: src/eCommerce.Web/eCommerce.Web.sln
    msbuildArgs: '/p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:SkipInvalidConfigurations=true /p:PackageLocation="$(Build.ArtifactStagingDirectory)"'
    platform: '$(BuildPlatform)'
    configuration: '$(BuildConfiguration)'
    clean: true
    maximumCpuCount: true
  enabled: true

UPDATE
After switching to the .NET Core task, I was able to get it working.

steps:
- task: DotNetCoreCLI@2
  displayName: 'dotnet build Functions'
  inputs:
    projects: 'src/**/*.Functions.csproj'
    arguments: '--output $(Build.BinariesDirectory)\Atlas.Ecommerce.Functions --configuration $(BuildConfiguration)'

One thing that threw me off is that the builld will fail if the "output" parameter has a slash in the wrong direction (for Windows).

@fabiocav
Copy link
Member

@MisinformedDNA thanks for that update, I'm sure it will be helpful to others.

I'm tracking to have the build fix as part of the tool in this coming sprint.

@panjevic
Copy link

@fabiocav Workaround posted above works when deploying locally. However, after publishing from Visual Studio, I get the error on the portal. What am I doing wrong?

Function (GetRecords) Error: Microsoft.Azure.WebJobs.Host: Error indexing method 'GetRecords'. Microsoft.Azure.WebJobs.Extensions.Storage: Can't bind Table to type 'Microsoft.WindowsAzure.Storage.Table.CloudTable'.

@dnetguru
Copy link

I'm seeing the same issue with Microsoft.Azure.WebJobs.Extensions.Storage v3.0.7 and WindowsAzure.Storage v9.3.3. I'm seeing the following message in the protal:

Function (QueueConsumer/LogUpdater) Error: Microsoft.Azure.WebJobs.Host: Error indexing method 'LogUpdater'. Microsoft.Azure.WebJobs.Extensions.Storage: Can't bind Table to type 'Microsoft.WindowsAzure.Storage.Table.CloudTable'.

@soninaren
Copy link
Member

@panjevic
If you are deploying to a function app that is being hosted on consumption plan then add a new application setting WEBSITE_USE_PLACEHOLDER= 0. Please note that setting this value would increase cold start duration for the function app (only for apps hosted on consumption). However this is not a permanent fix and there would be a proper fix that would not require you to add this app setting.

@daerath
Copy link

daerath commented Aug 29, 2019

@dnetguru

I'm having the same issue. v3.0.6 and v3.0.7 fail with the same error you're seeing.

@panjevic
Copy link

panjevic commented Sep 4, 2019

@soninaren Unfortunately this doesn't work for me, I'm still seeing the same issue. Tried creating new Function app and upgrading to v3.0.7 but that didn't work either.

@barryt2
Copy link

barryt2 commented Sep 12, 2019

@panjevic I also encountered this issue where the workaround suggested by fabiocav worked locally but not when I do a publish. In my case my publish is a ZIP deploy. After searching the web for a day, I finally got it to work for the publish scenario using the below. The main difference is instead of doing a AfterTargets against AfterPublish, I instead do a BeforeTargets against CreateZipFile. Hope this helps you or others facing similar issues. I found the solution from AtOMiCNebula on link: #3568

<Target Name="PostBuild" AfterTargets="PostBuildEvent">
  <Exec Command="copy $(OutDir)$(ProjectName).deps.json $(OutDir)bin\function.deps.json" />
</Target>
<Target Name="PostPublish" BeforeTargets="CreateZipFile">
  <Exec Command="copy $(PublishDir)$(ProjectName).deps.json $(PublishDir)bin\function.deps.json" />
</Target>

@barryt2
Copy link

barryt2 commented Sep 12, 2019

Oh and this worked for me without needing to do: WEBSITE_USE_PLACEHOLDER= 0

@APIWT
Copy link

APIWT commented Sep 25, 2019

@fabiocav Can we get an update on this?

@APErebus
Copy link

APErebus commented Oct 16, 2019

I'm running into this issue when using Microsoft.Azure.WebJobs.Extensions.DurableTask 2.0.0-beta3 and Microsoft.Azure.WebJobs.Extensions.Storage 3.0.8.

Durable tasks references WindowsAzure.Storage 9.3.3 where as Storage references WindowsAzure.Storage 9.3.1.

fyi. @cgillum

@cgillum
Copy link
Member

cgillum commented Oct 16, 2019

@APErebus This is a regression in the Durable Functions v2.0.0-beta3 release. We're tracking it here: Azure/azure-functions-durable-extension#975

@APErebus
Copy link

@APErebus This is a regression in the Durable Functions v2.0.0-beta3 release. We're tracking it here: Azure/azure-functions-durable-extension#975

@cgillum Awesome. Thanks for the info :)

@soninaren
Copy link
Member

Closing this one as the original issue has been resolved. For the issue related to durable functions refer to Azure/azure-functions-durable-extension#975

@ghost ghost locked as resolved and limited conversation to collaborators Jan 1, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests