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

Error for pre-release v1.16.3: TypeError: Cannot destructure property 'folder' of 'undefined' as it is undefined. {} #3321

Closed
tophoo opened this issue Aug 31, 2023 · 2 comments
Labels
bug a bug in the product Feature: tasks
Milestone

Comments

@tophoo
Copy link

tophoo commented Aug 31, 2023

Brief Issue Summary

When using cmake.getLaunchTargetFilename inside an input context of a task, e.g.:

{
    "inputs": [
        {
            "command": "cmake.getLaunchTargetFilename",
            "type": "command",
            "id": "cmake-target-filename"
        }
    ],
    "tasks": [
        {
            "command": "echo ${input:cmake-target-filename}",
            "label": "run task with bug",
            "type": "shell",
            "problemMatcher": []
        },
    ]
}

the error

Unhandled exception: Unhandled Promise rejection: getLaunchTargetFilename TypeError: Cannot destructure property 'folder' of 'undefined' as it is undefined. {}

occurs. With v1.15 everything works fine. The error was probably introduced with #2801. We rely on getting various cmake commands as input for other tasks.

CMake Tools Diagnostics

No response

Debug Log

No response

Additional Information

No response

@gcampbell-msft
Copy link
Collaborator

@tophoo Thanks for reporting the issue! We will attempt to reproduce and investigate this issue.

@gcampbell-msft gcampbell-msft added this to the 1.16 milestone Sep 1, 2023
@microsoft microsoft deleted a comment from github-actions bot Sep 7, 2023
@gcampbell-msft gcampbell-msft added investigation needed issues needs a developer assigned to it and investigation done in order to implement a fix fixed (release pending) and removed investigate investigation needed issues needs a developer assigned to it and investigation done in order to implement a fix labels Oct 4, 2023
Copy link

🎉 This issue has now been fixed and is now available in the latest release! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug a bug in the product Feature: tasks
Projects
None yet
Development

No branches or pull requests

3 participants