azure-sdk-for-js
azure-sdk-for-js copied to clipboard
Runtime version variables come null. Have they been deprecated and replaced with linuxFxVersion and windowsFxVersion?
- Package Name: @azure/arm-appservice
- Package Version: 14.0.0
- Operating system: Ubuntu 22.04.3 LTS
- [x] nodejs
- version: v16.20.1
- [ ] browser
- name/version:
- [ ] typescript
- version:
- Is the bug related to documentation in
- [ ] README.md
- [x] source code documentation
- [x] SDK API docs on https://docs.microsoft.com
Describe the bug
"netFrameworkVersion": null,
"phpVersion": null,
"pythonVersion": null,
"nodeVersion": null,
"powerShellVersion": null,
"linuxFxVersion": "PYTHON|3.10",
"windowsFxVersion": null,
I have a Web App running on Code - Python 3.10 runtime but when I see the value on UI JSON or fetch using CLI or JS SDK or REST API, pythonVersion
comes as null whereas it should have been 3.10
but linuxFxVersion
reports the right value which also matches with the list produced from CLI command az webapp list-runtimes
.
To Reproduce Steps to reproduce the behavior:
- Create a Web App - Code and Configure your Stack Runtime.
- Visit the overview page and open JSON view.
- Check using
az webapp
CLI command.
Expected behavior According to stack configuration, appropriate runtime variable should return value instead of null.
Screenshots
Web App Stack Runtime Configuration on Configuration Page
Web App Stack Runtime Configuration on Overview Page
UI JSON
Additional context Add any other context about the problem here.
If I understand correctly, CLI is parsing the value from runtime majorVersions or minorVersions. https://github.com/Azure/azure-cli/blob/56d778e6ff2f6032ea47eb63727fa1308a390d76/src/azure-cli/azure/cli/command_modules/appservice/custom.py#L3166-L3173 https://github.com/Azure/azure-cli/blob/56d778e6ff2f6032ea47eb63727fa1308a390d76/src/azure-cli/azure/cli/command_modules/appservice/custom.py#L3314-L3365 which is hard coded in Azure CLI.
Hi @akumar-99. Thank you for opening this issue and giving us the opportunity to assist. To help our team better understand your issue and the details of your scenario please provide a response to the question asked above or the information requested above. This will help us more accurately address your issue.
Something from my personal notes will help.
-
PHP
- linux web app
-
siteConfig.linuxFxVersion
andlinuxFxVersion
from .getConfiguration() returns the correct value -
siteConfig.phpVersion
andphpVersion
from .getConfiguration() return the incorrect values (null and "") respectively
-
- windows web app
- UI shows support but the runtimes list
az webapp list-runtimes
does not show support - No related output in
siteConfig.linuxFxVersion
orlinuxFxVersion
from .getConfiguration() orsiteConfig.phpVersion
orphpVersion
from .getConfiguration()
- UI shows support but the runtimes list
- linux web app
-
Python
- linux web app
-
siteConfig.linuxFxVersion
andlinuxFxVersion
from .getConfiguration() returns the correct value -
siteConfig.pythonVersion
andpythonVersion
from .getConfiguration() return the incorrect values (null and "") respectively
-
- windows web app
- UI shows support but the runtimes list
az webapp list-runtimes
does not show support - No related output in
siteConfig.linuxFxVersion
orlinuxFxVersion
from .getConfiguration() orsiteConfig.pythonVersion
orpythonVersion
from .getConfiguration()
- UI shows support but the runtimes list
- linux web app
-
Node
- linux web app
-
siteConfig.linuxFxVersion
andlinuxFxVersion
from .getConfiguration() returns the correct value -
siteConfig.nodeVersion
andnodeVersion
from .getConfiguration() return the incorrect values (null and "")
-
- windows web app
- Using this we can set nodejs version - https://learn.microsoft.com/en-us/azure/app-service/configure-language-nodejs?pivots=platform-windows#set-nodejs-version
- But the issue is we neither check if the app is using Node stack nor its version directly. We need to refer the settings variable which can be set for application irrespective of stack of web app.
- linux web app
-
Java
- linux web app
-
siteConfig.linuxFxVersion
andlinuxFxVersion
from .getConfiguration() returns the correct value -
siteConfig.javaVersion
andjavaVersion
from .getConfiguration() return the incorrect values (null and "")
-
- windows web app
-
javaVersion
andjavaContainer
andjavaContainerVersion
from .getConfiguration() gives me the right correct values -
siteConfig.windowsFxVersion
andwindowsFxVersion
from .getConfiguration() returns incorrect value -
siteConfig.javaVersion
andsiteConfig.javaContainer
andsiteConfig.javaContainerVersion
from .getConfiguration() return incorrect values
-
- linux web app
-
Go
- linux web app
-
siteConfig.linuxFxVersion
andlinuxFxVersion
from .getConfiguration() returns the correct value
-
- windows web app
- No support at all as expected
- linux web app
-
.NET (Also includes ASPNET for windows)
- linux web app
-
siteConfig.linuxFxVersion
andlinuxFxVersion
from .getConfiguration() returns the correct value -
siteConfig.netFrameworkVersion
andnetFrameworkVersion
from .getConfiguration() return the incorrect values ("v4.6" and "")
-
- windows
-
siteConfig.netFrameworkVersion
always returns "v4.6" irrespective of stack and versions configured -
netFrameworkVersion
from .getConfiguration() gives me the right value when .NET stack is configured but when a web app is configured with different stack, it still returns an arbitrary value. - Explained - https://github.com/Azure/azure-sdk-for-js/issues/26893
-
- linux web app
-
Ruby
- UI has the value but I am not sure if it is still supported. List runtimes does not show RUBY nor does any API response returns RUBY related information
- Only found in linux
@qiaozha So according to this then https://github.com/Azure/azure-cli/blob/56d778e6ff2f6032ea47eb63727fa1308a390d76/src/azure-cli/azure/cli/command_modules/appservice/custom.py#L3165 the null and "" values are by design?
Please elaborate further on major, minor versions parsing.
do you see any majorVersions or minorVersions informations when using client.provider.listWebAppStacks() apis ? I can not tell from your earlier screenshot.
No, there are no fields related to majorVersions or minorVersions in the outputs.
I have used appServiceClient.webApps.list()
and appServiceClient.webApps.getConfiguration(resourceGroupName,webAppName)
and neither has these two fields.
My issue might be the same, i have 2 app services, one runs on linux another one runs on windows . The properties.siteConfig.WindowsFxVersion --- for the app service which runs on windows OS returns null value , not sure what is wrong , but correctly populated for the app service which runs on linux OS
can someone send me insights on this , please
@qiaozha can you send some insights on my issue, thx ..