Command Name
az functionapp deployment source config-zip
root@pipejenkinstf:/test# az functionapp deployment source config-zip --resource-group myrandrg --name myuniquefunctj --src ./deploy.zip --verbose
Errors:
Unknown error
Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.
az functionapp deployment source config-zip --resource-group {} --name {} --src {} --debugLinux-4.9.0-11-amd64-x86_64-with-debian-9.11
Python 3.6.5
Shell: bash
azure-cli 2.0.81 *
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @ahmedelnably, @fabiocav
functionapp
@infrageek Is this an intermittent issue or does it happen when you try to redeploy? Can you also tell us what SKU you are using? (Linux consumption?)
@infrageek Is this an intermittent issue or does it happen when you try to redeploy? Can you also tell us what SKU you are using? (Linux consumption?)
Happens while redeploying
@infrageek Can you please share a repro or your function app name so we can investigate? Thanks.
Same issue.
Looks like generic available defect.
@anthonychu I've been experiencing this issue for like a year and figured with all the time at home I can finally help to fix it. :+1:
Function Env:
Function App I'm using - mikaeldevsite:
az functionapp create --consumption-plan-location $LOCATION \
--runtime python --runtime-version 3.8 --functions-version 3 \
--name $RESOURCE_NAME --storage-account $RESOURCE_NAME \
--os-type linux
Command Producing Error:
az functionapp deployment source config-zip --name $RESOURCE_NAME --src azure-web-img-dwnszr.zip
(See this script for a full example)
Error Produced:
Exact same as orig. post. The reason why I have dealt with this until now is because the .zip file is still created - I just need to ignore the error and all my scripts work fine.
Debug Investigations:
/azure-sdk-for-python/blob/master/sdk/appservice/azure-mgmt-web/azure/mgmt/web/v2019_08_01/operations/_web_apps_operations.py , line 24356 expects a return code of 204 from the API but 200 is returnedConclusion:
The Sync Function Triggers API is not returning the documented return code. Do you know the best way to engage with the Azure Functions team to get this fixed @anthonychu?
Debugging screenshot

Postman screenshot

Any updates on fixing this bug?
Im seeing this same problem when deploying a java functions app using azure cli.
I'm running:
my .deployment file
[config]
SCM_DO_BUILD_DURING_DEPLOYMENT=false
SCM_MAX_ZIP_PACKAGE_COUNT=1
My App Settings in the portal
SCM_DO_BUILD_DURING_DEPLOYMENT=false
WEBSITE_RUN_FROM_PACKAGE=1
az -v info
azure-cli 2.9.1
command-modules-nspkg 2.0.3
core 2.9.1
nspkg 3.0.4
telemetry 1.0.4
func -z info
3.0.2630
The command im running
az functionapp deployment source config-zip --name OBSCURED --resource-group OBSCURED --src functions.zip --debug
and the final output/failure
Syncing Triggers...
msrest.service_client : Accept header absent and forced to application/json
adal-python : c381a097-20f7-4fe5-b393-f8c4096775d5 - Authority:Performing instance discovery: ...
adal-python : c381a097-20f7-4fe5-b393-f8c4096775d5 - Authority:Performing static instance discovery
adal-python : c381a097-20f7-4fe5-b393-f8c4096775d5 - Authority:Authority validated via static instance discovery
adal-python : c381a097-20f7-4fe5-b393-f8c4096775d5 - TokenRequest:Getting token from cache with refresh if necessary.
adal-python : c381a097-20f7-4fe5-b393-f8c4096775d5 - CacheDriver:finding with query keys: {'_clientId': '...', 'userId': '...'}
adal-python : c381a097-20f7-4fe5-b393-f8c4096775d5 - CacheDriver:Looking for potential cache entries: {'_clientId': '...', 'userId': '...'}
adal-python : c381a097-20f7-4fe5-b393-f8c4096775d5 - CacheDriver:Found 7 potential entries.
adal-python : c381a097-20f7-4fe5-b393-f8c4096775d5 - CacheDriver:Resource specific token found.
adal-python : c381a097-20f7-4fe5-b393-f8c4096775d5 - CacheDriver:Returning token from cache lookup, AccessTokenId: b'OBSCURED=', RefreshTokenId: b'OBSCURED'
msrest.http_logger : Request URL: 'https://management.azure.com/subscriptions/OBSCURED/resourceGroups/dior/providers/Microsoft.Web/sites/OBSCURED/syncfunctiontriggers?api-version=2019-08-01'
msrest.http_logger : Request method: 'POST'
msrest.http_logger : Request headers:
msrest.http_logger : 'accept-language': 'en-US'
msrest.http_logger : 'Accept': 'application/json'
msrest.http_logger : 'User-Agent': 'python/3.8.5 (macOS-10.15.5-x86_64-i386-64bit) msrest/0.6.17 msrest_azure/0.6.3 azure-mgmt-web/0.47.0 Azure-SDK-For-Python AZURECLI/2.9.1 (HOMEBREW)'
msrest.http_logger : Request body:
msrest.http_logger : None
msrest.universal_http : Configuring redirects: allow=True, max=30
msrest.universal_http : Configuring request: timeout=100, verify=True, cert=None
msrest.universal_http : Configuring proxies: ''
msrest.universal_http : Evaluate proxies against ENV settings: True
urllib3.connectionpool : Starting new HTTPS connection (1): management.azure.com:443
urllib3.connectionpool : https://management.azure.com:443 "POST /subscriptions/OBSCURED/resourceGroups/OBSCURED/providers/Microsoft.Web/sites/OBSCURED/syncfunctiontriggers?api-version=2019-08-01 HTTP/1.1" 200 None
msrest.http_logger : Response status: 200
msrest.http_logger : Response headers:
msrest.http_logger : 'Cache-Control': 'private'
msrest.http_logger : 'Transfer-Encoding': 'chunked'
msrest.http_logger : 'Content-Type': 'application/json; charset=utf-8'
msrest.http_logger : 'Content-Encoding': 'gzip'
msrest.http_logger : 'ETag': '"1D66820F1614195"'
msrest.http_logger : 'Vary': 'Accept-Encoding'
msrest.http_logger : 'Strict-Transport-Security': 'max-age=31536000; includeSubDomains'
msrest.http_logger : 'Server': 'Microsoft-IIS/10.0'
msrest.http_logger : 'X-AspNet-Version': '4.0.30319'
msrest.http_logger : 'X-Powered-By': 'ASP.NET'
msrest.http_logger : 'x-ms-ratelimit-remaining-subscription-writes': '1198'
msrest.http_logger : 'x-ms-request-id': '384d301a-0626-43c0-bd03-8eefc1e8c211'
msrest.http_logger : 'x-ms-correlation-request-id': '384d301a-0626-43c0-bd03-8eefc1e8c211'
msrest.http_logger : 'x-ms-routing-request-id': 'WESTUS:20200801T162942Z:384d301a-0626-43c0-bd03-8eefc1e8c211'
msrest.http_logger : 'X-Content-Type-Options': 'nosniff'
msrest.http_logger : 'Date': 'Sat, 01 Aug 2020 16:29:42 GMT'
msrest.http_logger : Response content:
msrest.http_logger : {"status":"success"}
msrest.exceptions : Unknown error
cli.azure.cli.core.util : Unknown error
Unknown error
fwiw this is a show stopper...If i cant deploy i have to abandon azure functions
Thanks for the repro @mikaelweave. Super helpful. Sorry I missed it the first time. https://github.com/Azure/Azure-Functions/issues/1674
for anyone else struggling with azure cli, the func app from Azure Functions Core Tools works for deployment.
func azure functionapp publish <app-name> --no-build --java
i ran it directly from the staging folder:
|-- src/main/java
|-- pom.xml
|-- ...
|-- target
|-- azure-functions
|-- my-app <-- run from inside this folder
|-- host.json
|-- my-app.jar
|-- lib
|-- my-function
|-- function.json
alternative values for the different language runtimes:
[--csharp, --javascript, --typescript, --java, --python, --powershell]
Getting site publishing info...
Skipping build event for functions project (--no-build).
Uploading package...
Uploading 9.97 MB [###############################################################################]
Upload completed successfully.
Deployment completed successfully.
Syncing triggers...
Functions in OBSCURED:
... OBSCURED
I finally see my functions in the portal and can successfully invoke them 馃帀
@infrageek it might be helpful for other people searching to remove the word "python" from the issue title as this seems to be language/runtime agnostic.
I am encountering this exact same issue @bpossolo when i try to deploy it via Azure Devops, with the Az Cli Task.
Any solutions there?
I wrote the workaround two comments up. Use the azure functions cli tool instead.
I know, but the Azure Functions Core tools task in Azure Devops is still on preview, and i am not allowed to do it.
are you using java or python?
netcore
oh wow. It doesn鈥檛 even work for a .net app 馃う
Ummm... have you tried twiddling the 鈥攂uild-remote flag? It didn鈥檛 do anything for me.
The really painful workaround is to upload your zip to blob storage container then use the option to deploy from blob
Yes I did tried with the --build-remote flag, and it does not work either.
But I will give a try to that work around you mentioned there. Thanks.
It's seems that running it in a Windows host works.
Hope that's helpfull.
Hi Team,
We met this issue also, is there any ETA for this issue? thanks.
functionapp service team should look into this issue.
Hello, are there any news about this issue?
Most helpful comment
@anthonychu I've been experiencing this issue for like a year and figured with all the time at home I can finally help to fix it. :+1:
Function Env:
Function App I'm using -
mikaeldevsite:Command Producing Error:
az functionapp deployment source config-zip --name $RESOURCE_NAME --src azure-web-img-dwnszr.zip(See this script for a full example)
Error Produced:
Exact same as orig. post. The reason why I have dealt with this until now is because the
.zipfile is still created - I just need to ignore the error and all my scripts work fine.Debug Investigations:
/azure-sdk-for-python/blob/master/sdk/appservice/azure-mgmt-web/azure/mgmt/web/v2019_08_01/operations/_web_apps_operations.py, line 24356 expects a return code of204from the API but200is returnedConclusion:
The Sync Function Triggers API is not returning the documented return code. Do you know the best way to engage with the Azure Functions team to get this fixed @anthonychu?
Debugging screenshot

Postman screenshot
