Skip to content

Explicitly defining PowerShell resources doesn't allow for delete #1292

@Gijsreyn

Description

@Gijsreyn

Prerequisites

  • Write a descriptive title.
  • Make sure you are able to repro it on the latest version
  • Search the existing issues.

Summary

After the following pull request, I can create a configuration document like:

$schema: https://aka.ms/dsc/schemas/v3/bundled/config/document.json
resources:
- name: Basic workspace group
  type: DatabricksDsc/DatabricksAccountServicePrincipal
  properties: 
     Name: 'my-user'
     _exist: false

However, trying to execute the above throws an error: Resource 'DatabricksDsc/DatabricksAccountServicePrincipal' does not support deleteand does not handle_exist as false.

Whenever I wrap it around Microsoft.DSC/PowerShell , this doesn't happen because the adapter has the implementsPreTest set.

Steps to reproduce

Run the above configuration document

Expected behavior

The resource runs and deletes the service principal

Actual behavior

Resource 'DatabricksDsc/DatabricksAccountServicePrincipal' does not support `delete` and does not handle `_exist` as false

Error details

Environment data

Name                           Value
----                           -----
PSVersion                      7.5.4
PSEdition                      Core
GitCommitId                    7.5.4
OS                             Microsoft Windows 10.0.26100
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
WSManStackVersion              3.0

Version

dsc 3.2.0-preview.8

Visuals

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions