Skip to content

Running debugger against module manifest (psd1) file results in confusing error message #503

@pcgeek86

Description

@pcgeek86

If you hit F5 to invoke the debugger, and currently have a PowerShell module manifest file open, a confusing exception is thrown, and captured in the Visual Studio Code Debug Console.

Cannot run a document in the middle of a pipeline: c:\redacted\redacted.psd1.
At line:0 char:0

It'd be great to be able to set up multiple launch configurations, similar to how NPM works, so that hitting F5 isn't dependent on having the right file selected. For example, you might set up a launch configuration to invoke unit tests, or a separate one to publish the module to the PowerShell Gallery, etc. etc.

Cheers,
Trevor Sullivan
Docker Captain
Microsoft MVP: Cloud & Data Center Management
https://trevorsullivan.net
https://twitter.com/pcgeek86

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions