title: The listener for function was unable to start. Why?
body: <p>I'm getting the following error when I run the azure function from visual studio.</p>
  
  <blockquote>
    <p>A ScriptHost error has occurred [1/19/2018 6:40:52 AM] The listener
    for function 'MyFunctionName' was unable to start.
    Microsoft.WindowsAzure.Storage: Server encountered an internal error.
    Please try again after some time.</p>
  </blockquote>
  
  <p>When I run from the command prompt by running <code>func host start</code> command. I get the following warning. and then it gets stuck on </p>
  
  <blockquote>
    <p>Host lock lease acquired by instance ID</p>
  </blockquote>
  
  <p>.</p>
  
  <blockquote>
    <p>No job functions found. Try making your job classes and methods
    public. If you're using binding extensions (e.g. ServiceBus, Timers,
    etc.) make sure you've called the registration method for the
    extension(s) in your startup code (e.g. config.UseServiceBus(),
    config.UseTimers(), etc.).</p>
  </blockquote>
  
  <p>Azure function version: <code>azure-functions-core-tools@2.0.1-beta.22</code>
  I'm using Storage Accounts Blob containers and queues.</p>
  
  <p>I'm connecting to <strong>Development Storage account</strong>, I have checked it that <strong>storage emulator</strong> is started.</p>
  
  <pre><code>{
    "IsEncrypted": false,
    "Values": {
      "ConnectionStrings:Default": "Server=.\\SQLEXPRESS; Database=TestDb; Trusted_Connection=True;",
      "ConnectionStrings:BlobStorageAccount": "UseDevelopmentStorage=true",
  
      "AzureWebJobsStorage": "UseDevelopmentStorage=true",
      "AzureWebJobsDashboard": "UseDevelopmentStorage=true",
    }
  }
  </code></pre>
  
  <p><strong>FYI.</strong></p>
  
  <p>It was working fine before, But I have got this message in Visual Studio.</p>
  
  <blockquote>
    <p>your license has gone stale and must be updated. Check for an updated
    license to continue using this product</p>
  </blockquote>
  
  <p>So I just deleted the <strong>%localappdata%</strong> and <strong>%temp%</strong>, then I tried to run Azure function and after this, I have started getting</p>
  
  <blockquote>
    <p>The listener for function was unable to start error</p>
  </blockquote>
  
  <p>So is it related to my visual studio subscription or I mistakenly deleted any required file? Or is this related to something else?</p>