Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Azure policy creation failure in windows-latest #10428

Closed
3 of 13 tasks
kevinzhg opened this issue Aug 12, 2024 · 8 comments
Closed
3 of 13 tasks

Azure policy creation failure in windows-latest #10428

kevinzhg opened this issue Aug 12, 2024 · 8 comments

Comments

@kevinzhg
Copy link

kevinzhg commented Aug 12, 2024

Description

Azure policy creation failure in windows-latest

Current image version: '20240807.2.0'
AZ version is 12.1.0

##[error][InvalidRequestContent] : The request content was invalid and could not be deserialized: 'Error converting value "@{type=String; metadata=}" to type 'Microsoft.WindowsAzure.Governance.PolicyService.Models.Policy.PolicyParameterDefinition'. Path 'properties.parameters.effect', line 18, position 43.'. the block below is the one I am using.

"parameters": {
  "effect": {
    "type": "String",
    "defaultValue": "Append",
    "allowedValues": [
      "Append",
      "Disabled"
    ],
    "metadata": {
      "displayName": "Effect",
      "description": "Enable or disable the execution of the policy"
    }
  }
}

Platforms affected

  • Azure DevOps
  • GitHub Actions - Standard Runners
  • GitHub Actions - Larger Runners

Runner images affected

  • Ubuntu 20.04
  • Ubuntu 22.04
  • Ubuntu 24.04
  • macOS 12
  • macOS 13
  • macOS 13 Arm64
  • macOS 14
  • macOS 14 Arm64
  • Windows Server 2019
  • Windows Server 2022

Image version and build link

Current image version: '20240807.2.0'
AZ version is 12.1.0

Is it regression?

no

Expected behavior

No error.

Actual behavior

##[error][InvalidRequestContent] : The request content was invalid and could not be deserialized: 'Error converting value "@{type=String; metadata=}" to type 'Microsoft.WindowsAzure.Governance.PolicyService.Models.Policy.PolicyParameterDefinition'. Path 'properties.parameters.effect', line 18, position 43.'.

Repro steps

  1. Using windows-latest version in Azure DevOps.
  2. Creating the azure policy according to https://github.com/Azure/ALZ-Bicep/blob/main/infra-as-code/bicep/modules/policy/definitions/lib/policy_definitions/policy_definition_es_Append-KV-SoftDelete.json
  3. you will see the error.
@kishorekumar-anchala
Copy link
Contributor

kishorekumar-anchala commented Aug 13, 2024

Hi @kevinzhg ,

Thank you for bringing this issue to us. We will look into this issue and will update you on this issue after investigating

@kishorekumar-anchala
Copy link
Contributor

Hi @kevinzhg ,

It seems below repo is the appropriate to raise issue about your bug. Please check the below repo . thank you !

https://github.com/Azure/ALZ-Bicep/issues

@kevinzhg
Copy link
Author

Hi @kevinzhg ,

It seems below repo is the appropriate to raise issue about your bug. Please check the below repo . thank you !

https://github.com/Azure/ALZ-Bicep/issues

As a temporary solution, we switched the agent version to windows-2019, and it worked well until midnight. We noticed the change in the image from (Current image version: '20240730.1.0') to (Current image version: '20240811.1.0'). Could you direct me to where I can find the release notes for the '20240811.1.0' version? if there have been any changes introduced in this image related to the deserialization in 'Microsoft.WindowsAzure.Governance.PolicyService.Models.Policy.PolicyParameterDefinition'. thanks in advance.

@kishorekumar-anchala
Copy link
Contributor

Hi @kevinzhg

please find below urls.

win-19 and win-22

@kishorekumar-anchala
Copy link
Contributor

HI @kevinzhg ,

do we have any update?

@kishorekumar-anchala
Copy link
Contributor

Hi @kevinzhg ,

We hope you're issue got resolved , could you please share your comments ?

@kishorekumar-anchala
Copy link
Contributor

Hi @kevinzhg , we hope the issue got resolved , we are closing the issue.

@almirayasmin
Copy link

Is there any resolution to this issue? I face the same problem

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants