Skip to content

Better error message when no input is provided to PowerShell adapters #516

Closed
@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

Executing: dsc resource get --resource Microsoft.DSC/PowerShell throws an error "Exception calling "Invoke" with "2" argument(s): "Conversion from JSON failed with error: Unexpected character encountered while parsing value: @. Path '', line 0"

Steps to reproduce

dsc resource get --resource Microsoft.DSC/PowerShell

Expected behavior

Message indicating the issue.

Actual behavior

Exception calling "Invoke" with "2" argument(s): "Conversion from JSON failed with error: Unexpected character encountered while parsing value: @. Path '', line 0

Error details

No response

Environment data

Name                           Value
----                           -----
PSVersion                      7.4.3
PSEdition                      Core
GitCommitId                    7.4.3
OS                             Microsoft Windows 10.0.22631
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.0.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