Azure / Azure/Azure-Functions

Function app name length issue

Open
#2,395 14 comments 3 reactions 1 assignee Claimed by @bhagyshricompany View on GitHub
bug Needs: Author feedback
Dominant language
PowerShell
Stars
1.1k
Forks
215
Avg merge
4h 2m
Merged PRs (30d)
1

Description

I am facing an issue with the function app name.
I created an Azure function with the name `abcde-product-stats-and-release-notes-api` and created a `staging` slot in the same.
Function app name: `abcde-product-stats-and-release-notes-api`
URL: https://abcde-product-stats-and-release-notes-api.azurewebsites.net

Slot-Name: `staging`
URL: https://abcde-product-stats-and-release-notes-ap-staging.azurewebsites.net (_last character from `api` is trimmed_)
On clicking on the URL got this
![image](https://github.com/Azure/Azure-Functions/assets/96179664/16f8afe5-0e89-484e-9d7d-498be3d8efff)

While deploying to the staging slot using GitHub actions, got error:
`Error: Execution Exception (state: ValidateParameter) (step: Invocation)
Error: At ValidateParameter, slot-name : SCM credential does not match slot-name staging. Please ensure the slot-name parameter has correct casing and the publish profile is acquired from your function app's slot rather than your main production site..
Error: Deployment Failed!`
_The error message is misleading and wasted too much time debugging this._

I finally created another function app with the name `abcde-product-stats-reno-api` and then staging slot in the same, deployment was successful and everything is working as expected.
Also found another weird thing in the deployment center is :
![image](https://github.com/Azure/Azure-Functions/assets/96179664/88c66c41-1bc6-4e37-b1bf-5f535b71b351)

Functions are deployed to the staging slot but in the `message` section of the logs `**"slotName":"production"**` which is wrong it should be `staging`

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.