'Azure Function App running old code when deployments are successful
My Linux Python function app is refusing to run the most recent code deployed to it. I've tried deploying via Visual studio code and GitHub which does work as I can see the code within the "Code + Test" section within the function, but the function app refuses to run it.
I've tried restarting and the different deployment methods but have now run out of ideas on why this is happening.
Solution 1:[1]
Deployed the Azure Functions Python (3.9.9 Version) Http Trigger to Azure Function App:

Changed the HTTP Trigger code to get the ID parameter in the function URL along with the response string and published to Azure:


It took a minute or two to replace the new code in the "Code+Test" Section of the Portal of Azure Function App HTPT Trigger.
And for the first time, if any code changes to the Project and that has to be picked by Azure from the GitHub, it takes 5 to 10 minutes long only for the 1st time in order to reflect the changes of code made and sometimes too long, that depends on the external libraries used and Number of files present in the project to sync with Azure.
Please refer to the workarounds of the similar issues:
- Continuous deployment from GitHub takes several minutes
- Increase deployment speed of Azure Functions https://github.com/Azure/functions-action/issues/61
If this issue persists and takes a long time for simple function code, then please raise a ticket with Microsoft Support.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | HariKrishnaRajoli-MT |
