[Question]: Any bicep file for ARM Template deployment gives the error: "Task failed while parsing with following error: Unexpected token p in JSON at position 0." #20795
Open
Description
Task name
ARM Template deployment
Task version
3.x.x
Environment type (Please select at least one enviroment where you face this issue)
- Self-Hosted
- Microsoft Hosted
- VMSS Pool
- Container
Azure DevOps Server type
dev.azure.com (formerly visualstudio.com)
Azure DevOps Server Version (if applicable)
Version Azure DevOps Server 2020 Update 1.2
Operation system
Windows Server 2016 Datacenter
Question
I get the same error with any bicep file I try:
2025-01-21T16:23:45.0332306Z ##[error]Error: Ensure the Template file ( 'F:\DEVPipeline\agent\_work\r6\a\_dev\drop\dev-kv\template.bicep' ) is valid. Task failed while parsing with following error: Unexpected token p in JSON at position 0
The agent has Bicep CLI version 0.32.4 and Azure-CLI 2.67.0. The bicep file starts with `param` so it seems like it errors at the very beginning and since it mentions JSON, it seems to be expecting ARM instead of bicep. I don't know how to determine the specific task version. I have it set to use 3 so it should use the latest. The Bicep and Azure CLI versions are the latest at this time and meet the minimum for bicep support for the task. The bicep file is valid, exported from a working environment and decompiled. I've tried other bicep files as well and I get the same issue with all of them.