No visible error in SWA managed Azure Functions (Node.js) when API dependency installation fails during deployment
- Dominant language
- No language data
- Stars
- 346
- Forks
- 67
- PR merge metrics
- No merged PRs in 30d
Description
# No visible error in SWA managed Azure Functions (Node.js) when API dependency installation fails during deployment
## Description
When deploying a Node.js API to Azure Functions (managed via Azure Static Web Apps), if there’s a failure while installing API dependencies (e.g., during `npm ci` in the `api/` folder), the deployment completes without surfacing the error anywhere in the Azure Portal.
## Impact
- The **APIs** blade in the Azure Static Web Apps portal simply does not show the API.
- There’s no clear indication in the Azure Portal that dependency installation failed.
- Without Application Insights (unavailable because the function isn’t bound/created), developers have no way to see the root cause.
- This results in **silent failures** where APIs are missing after deployment, but no logs indicate the installation issue.
## Expected Behavior
If dependency installation fails, the deployment should clearly mark this as an **error** in:
- The deployment logs in the Azure Portal
- The Static Web Apps build logs
- The Function App log stream
## Actual Behavior
- No visible error in Azure Portal.
- API simply not listed under **APIs** in SWA portal.
- Only way to find the error is by inspecting the full CI/CD logs (e.g., GitHub Actions with Oryx build output).
## Steps to Reproduce
1. Deploy a Node.js API to Azure Functions (via SWA managed API) where `npm ci` will fail
(e.g., missing `package-lock.json` or incompatible dependency versions).
2. Let the deployment complete.
3. Observe:
- The API is not visible in the SWA portal.
- No error message is shown in Azure Portal.
- Only deep inspection of CI/CD logs reveals the root cause.
## Environment
- **Platform**: Azure Static Web Apps with managed Azure Functions API
- **Node.js**: v18.x / v20.x
- **Deployment**: GitHub Actions & SWA CLI
## Suggestion
Add a clear error indicator in the Azure Portal and surface the dependency installation failure reason directly in the deployment summary for managed APIs.
**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
**Describe the solution you'd like**
A clear and concise description of what you want to happen.
**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.
**Additional context**
Add any other context or screenshots about the feature request here.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.