Skip to content

workbench.action.tasks.build no longer triggers build but opens a list of tasks #130028

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

Closed
borgdylan opened this issue Aug 3, 2021 · 6 comments · Fixed by #130043
Closed

workbench.action.tasks.build no longer triggers build but opens a list of tasks #130028

borgdylan opened this issue Aug 3, 2021 · 6 comments · Fixed by #130043
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug candidate Issue identified as probable candidate for fixing in the next release insiders-released Patch has been released in VS Code Insiders tasks Task system issues verified Verification succeeded
Milestone

Comments

@borgdylan
Copy link

Does this issue occur when all extensions are disabled?: Yes

  • Version: 1.59.0-insider
  • Commit: ba0df88
  • Date: 2021-07-31T00:42:32.346Z
  • Electron: 13.1.7
  • Chrome: 91.0.4472.124
  • Node.js: 14.16.0
  • V8: 9.1.269.36-electron.0
  • OS: Linux x64 5.13.5

Steps to Reproduce:

  1. Open a project directory that is hooked up with tasks via tasks.json v2. The tasks.json file must define one of the tasks as being the default.
  2. Ensure you have workbench.action.tasks.build bound to a shortcut (mine is ctrl+shift+b)
  3. Press the key combination to trigger the build
  4. A picker combobox to choose a task appears instead of the default task being executed as used to happen before.
@alexr00
Copy link
Member

alexr00 commented Aug 3, 2021

@borgdylan I'm not able to reproduce this issue. Do you have a repository I can test with? I tried with:
https://github.com/microsoft/vscode
https://github.com/microsoft/vscode-pull-request-github

If there is more than one default build task, then we have always shown the picker. If there is only one default build task, then we run it.

@alexr00 alexr00 added the info-needed Issue requires more information from poster label Aug 3, 2021
@borgdylan
Copy link
Author

I'm experiencing this with internal company code which cannot be shared. I can share the tasks.json file. It should work with any c# based project.

@borgdylan
Copy link
Author

Has the schema for tasks.json changed at all in the past month?

@borgdylan
Copy link
Author

borgdylan commented Aug 3, 2021

{
    // See https://go.microsoft.com/fwlink/?LinkId=733558
    // for the documentation about the tasks.json format
    "version": "2.0.0",
    "tasks": [
        {
            "group": "build",
            "label": "build-js",
            "type": "shell",
            "command": "gulp",
            "args": []
        },
        {
            "group": {"kind": "build", "isDefault": true},
            "dependsOn":["build-js"],
            "label": "build",
            "type": "shell",
            "command": "msbuild",
            "args": ["/property:GenerateFullPaths=true", "/t:Build"],
            "problemMatcher": [
                {
                    "owner": "dylandotnet",
                    "fileLocation": ["absolute"],
                    "pattern": {
                        "regexp": "^(.*)\\((\\d+)(,(\\d+))?\\):\\s*(error|warning)\\s*:\\s*(.*)$",
                        "file": 1,
                        "line": 2,
                        "column": 4,
                        "severity": 5,
                        "message": 6
                    }
                },
                "$msCompile"
            ]
        },
        {
            "label": "restore",
            "type": "shell",
            "command": "msbuild",
            "args": ["/property:GenerateFullPaths=true", "/t:Restore"],
            "problemMatcher": [
                "$msCompile"
            ]
        }
    ]
}

@borgdylan
Copy link
Author

I've replicated this on other similar projects, even those that have just one task defined.

@alexr00 alexr00 added bug Issue identified by VS Code Team member as probable bug candidate Issue identified as probable candidate for fixing in the next release tasks Task system issues and removed info-needed Issue requires more information from poster labels Aug 3, 2021
@alexr00 alexr00 added this to the July 2021 milestone Aug 3, 2021
@alexr00
Copy link
Member

alexr00 commented Aug 3, 2021

Thanks for the additional details and for reporting this issue!

@alexr00 alexr00 closed this as completed in f3e4e0b Aug 3, 2021
@rzhao271 rzhao271 added the verified Verification succeeded label Aug 3, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Sep 17, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug candidate Issue identified as probable candidate for fixing in the next release insiders-released Patch has been released in VS Code Insiders tasks Task system issues verified Verification succeeded
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants
@rzhao271 @borgdylan @alexr00 and others