Giter Site home page Giter Site logo

Comments (6)

alex-frankel avatar alex-frankel commented on July 29, 2024 1

Looks like a swagger issue. They types changed in the most recent released. The previous type definition we had did not mark these properties as read-only. I will open an issue in the swagger repo.

@miqm - this also seems related to our logic for making type errors with top level properties warnings instead of errors. This type issue should be non-blocking.

@MartinHannemann -- if it's critical, reverting to an older version of bicep should fix this.

from bicep-types-az.

miqm avatar miqm commented on July 29, 2024 1

On the other hand, we should have some type tests that when we prepare a package upgrade to review what was changed and perhaps catch that sort of changes and verify them manually if they're correct or not.

from bicep-types-az.

alex-frankel avatar alex-frankel commented on July 29, 2024 1

Looks like the swagger may not be the issue based on this response?


Hi Alex,

Reaching out to you for the git hub issue that is opened recently. In our swagger definition these properties are not marked as read-only. Also there has been no changes in the swagger definition for this API.

Link to swagger repo for these parameters which are shown as read-only: https://github.com/Azure/azure-rest-api-specs/blob/e5a0d0d5f7b69554dc6cc27455e86155306444b2/specification/automation/resource-manager/Microsoft.Automation/stable/2019-06-01/dscConfiguration.json#L455

Could you help with this?

Thanks,
Jagpreet Singh

from bicep-types-az.

alex-frankel avatar alex-frankel commented on July 29, 2024

It's because you are using are using the existing keyword in the resource declaration which is a way to reference previously created resources to read properties from it. It makes the type of the entire resource read-only. If you are looking to create or update the resource, you should remove that keyword.

EDIT: misread the screenshot - sorry! Will send a new response soon.

from bicep-types-az.

miqm avatar miqm commented on July 29, 2024

Seems that all type-related issues should be warnings, never errors. I think we left those that are coming from swagger assuming swagger will be accurate for top-level ones. Seems we're wrong.

from bicep-types-az.

alex-frankel avatar alex-frankel commented on July 29, 2024

Leaving this open to track the swagger issue, but it is no longer Top 5

from bicep-types-az.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.