Skip to content
This repository has been archived by the owner on Nov 18, 2022. It is now read-only.

No tasks in VSC 1.25.0 #359

Closed
Barugon opened this issue Jul 5, 2018 · 19 comments
Closed

No tasks in VSC 1.25.0 #359

Barugon opened this issue Jul 5, 2018 · 19 comments
Labels
Milestone

Comments

@Barugon
Copy link

Barugon commented Jul 5, 2018

The default tasks are no longer available after upgrading to VSC 1.25.0.

To duplicate, upgrade to VSC 1.25.0, click the Tasks menu, click the Run Task menu item item and note that the list is now empty.

@HyperHamster
Copy link

Issue confirmed with VSCode 1.25.0 on Arch Linux x86_64.

@agentsim
Copy link

agentsim commented Jul 6, 2018

Also happening with VSCode 1.25.0 on Fedora 28.

@hpesoj
Copy link

hpesoj commented Jul 6, 2018

Confirmed on Windows 10 as well.

@nrc nrc added this to the 1.0 milestone Jul 6, 2018
@nrc nrc added the bug label Jul 6, 2018
@TomMarius
Copy link

Could someone please share a template in the meantime until it's fixed?

@fj
Copy link
Contributor

fj commented Jul 8, 2018

In the meantime, you can get the tasks by looking at the source; they're added here: https://github.com/rust-lang-nursery/rls-vscode/blob/master/src/tasks.ts#L88-L169

Here is the implicit tasks.json that would have been generated:

{
  // See https://go.microsoft.com/fwlink/?LinkId=733558
  // for the documentation about the tasks.json format
  "version": "2.0.0",
  "tasks": [
    {
      "type": "shell",
      "label": "cargo build",
      "command": "cargo",
      "args": [
        "build"
      ],
      "problemMatcher": [
        "$rustc"
      ]
    },
    {
      "type": "shell",
      "label": "cargo check",
      "command": "cargo",
      "args": [
        "check"
      ],
      "problemMatcher": [
        "$rustc"
      ]
    },
    {
      "type": "shell",
      "label": "cargo clean",
      "command": "cargo",
      "args": [
        "clean"
      ],
      "problemMatcher": []
    },
    {
      "type": "shell",
      "label": "cargo run",
      "command": "cargo",
      "args": [
        "run"
      ],
      "problemMatcher": [
        "$rustc"
      ]
    },
    {
      "type": "shell",
      "label": "cargo test",
      "command": "cargo",
      "args": [
        "test"
      ],
      "problemMatcher": [
        "$rustc"
      ]
    }
  ]
}

@nrc
Copy link
Member

nrc commented Jul 8, 2018

Fixed by #361

@fj
Copy link
Contributor

fj commented Jul 8, 2018

Confirmed that this works for me. Thank you @nrc and @HyperHamster!

@nrc
Copy link
Member

nrc commented Jul 8, 2018

Released 0.4.7 with this fix

@Barugon
Copy link
Author

Barugon commented Jul 9, 2018

Works for me, thanks.

@scautura
Copy link

scautura commented Jul 9, 2018

I'm still having a few issues. I get the tasks showing up, but when I try to use one (doesn't matter which one), I get:
> Executing task in folder ProjectFolder: cargo task <
Followed by nothing (doesn't seem to run at all); where task is one of run, build, check, bench, clean, or test.

If I "Configure Tasks" and change "type": "cargo", to "type": "shell",, it runs as expected. If I run cargo task from the command line, it runs as expected.

I've tested with a few projects, even just a basic "Hello World" style project!

@TomMarius
Copy link

@scautura Yes, happens to me as well (Windows 10)

@corberan
Copy link

@TomMarius +1

@hpesoj
Copy link

hpesoj commented Jul 14, 2018

If you try to "Configure Task", the generated task has "cargo" in the "type" field. Apparently, this should be "shell" or "process". Here is a fixed tasks.json:

{
    "version": "2.0.0",
    "tasks": [
        {
            "type": "shell",
            "label": "cargo build",
            "command": "cargo",
            "args": [
                "build"
            ],
            "problemMatcher": [
                "$rustc"
            ],
            "group": "build"
        },
        {
            "type": "shell",
            "label": "cargo check",
            "command": "cargo",
            "args": [
                "check"
            ],
            "problemMatcher": [
                "$rustc"
            ],
            "group": "build"
        },
        {
            "type": "shell",
            "label": "cargo run",
            "command": "cargo",
            "args": [
                "run"
            ],
            "problemMatcher": [
                "$rustc"
            ],
        },
        {
            "type": "shell",
            "label": "cargo test",
            "command": "cargo",
            "args": [
                "test"
            ],
            "problemMatcher": [
                "$rustc"
            ],
            "group": "test"
        },
        {
            "type": "shell",
            "label": "cargo bench",
            "command": "cargo",
            "args": [
                "+nightly",
                "bench"
            ],
            "problemMatcher": [
                "$rustc"
            ],
            "group": "test"
        },
        {
            "type": "shell",
            "label": "cargo clean",
            "command": "cargo",
            "args": [
                "clean"
            ],
            "problemMatcher": []
        },
    ]
}

@nrc
Copy link
Member

nrc commented Jul 19, 2018

cc @matklad re the last comment. Would you expect changing the type to cargo to break things?

@matklad
Copy link
Member

matklad commented Jul 19, 2018

No, I think we must define a fresh type of tasks to make things work. I am not too sure about this, but, for example, cake defines the new type:
microsoft/vscode#53673 (comment).

I wonder what distinguish setups of people for whom type cargo does not work?

@matklad
Copy link
Member

matklad commented Jul 19, 2018

I think this might be the fix: #376. However, I still can't reproduce the issue locally, on


Version: 1.25.0
Commit: 0f080e5267e829de46638128001aeb7ca2d6d50e
Date: 2018-07-05T13:10:37.273Z
Electron: 1.7.12
Chrome: 58.0.3029.110
Node.js: 7.9.0
V8: 5.8.283.38
Architecture: x64

everything seems to work even with 'rust'.

@matklad
Copy link
Member

matklad commented Jul 19, 2018

Reprodced, this is windows specific.

@matklad
Copy link
Member

matklad commented Jul 19, 2018

Ok, the actual fix is #371 :)

@nrc
Copy link
Member

nrc commented Jul 20, 2018

Closed by #371

@nrc nrc closed this as completed Jul 20, 2018
Xanewok pushed a commit to Xanewok/rls-vscode that referenced this issue Mar 27, 2019
… r=alexheretic

Bump jsonrpc-core from 9.0.0 to 10.0.1

Bumps [jsonrpc-core](https://github.com/paritytech/jsonrpc) from 9.0.0 to 10.0.1.
<details>
<summary>Release notes</summary>

*Sourced from [jsonrpc-core's releases](https://github.com/paritytech/jsonrpc/releases).*

> ## JSON-RPC v10.0.1
> Fixes documentation links and authors.
>
> ```
> jsonrpc-core = "10.0.1"
> jsonrpc-macros = "10.0.1"
> jsonrpc-derive = "10.0.1"
> jsonrpc-pubsub = "10.0.1"
> jsonrpc-server-utils = "10.0.1"
> jsonrpc-http-server = "10.0.1"
> jsonrpc-ipc-server = "10.0.1"
> jsonrpc-tcp-server = "10.0.1"
> jsonrpc-ws-server = "10.0.1"
> jsonrpc-stdio-server = "10.0.1"
> jsonrpc-test = "10.0.1"
> ```
>
> ## JSON-RPC v10.0.0
> This is an exciting release, because it's the first time we release all parts of the suite to crates.io! So long github dependencies!
>
> Most notable changes:
> 1. Deprecating `jsonrpc-macros` in favour of `jsonrpc-derive` (proc-macro based)
> 2. Rewrting all crates to `edition = 2018`
>
> Other changes:
> - Adding `Metadata` to unsubscribe methods (when they are called explicitly)
> - Derive `Clone` for all `core` types
> - Fix custom bounds on the types in `jsonrpc-macros`
> - Fix charset case sensitivity for http server
>
>
> Full list of changes: paritytech/jsonrpc@v9.0.0...v10.0.0
>
> ```
> jsonrpc-core = "10.0.0"
> jsonrpc-macros = "10.0.0"
> jsonrpc-pubsub = "10.0.0"
> jsonrpc-server-utils = "10.0.0"
> jsonrpc-http-server = "10.0.0"
> jsonrpc-ipc-server = "10.0.0"
> jsonrpc-tcp-server = "10.0.0"
> jsonrpc-ws-server = "10.0.0"
> jsonrpc-stdio-server = "10.0.0"
> jsonrpc-test = "10.0.0"
> ```
</details>
<details>
<summary>Commits</summary>

- [`8ffc7f3`](paritytech/jsonrpc@8ffc7f3) Add jsonrpc-derive details. ([rust-lang#372](https://github-redirect.dependabot.com/paritytech/jsonrpc/issues/372))
- [`2fe3bfc`](paritytech/jsonrpc@2fe3bfc) One way serialize for subscriber type ([rust-lang#371](https://github-redirect.dependabot.com/paritytech/jsonrpc/issues/371))
- [`37b62a3`](paritytech/jsonrpc@37b62a3) Migrate to edition 2018 ([rust-lang#368](https://github-redirect.dependabot.com/paritytech/jsonrpc/issues/368))
- [`5a7be5f`](paritytech/jsonrpc@5a7be5f) Bump version of stdio ([rust-lang#367](https://github-redirect.dependabot.com/paritytech/jsonrpc/issues/367))
- [`2b47a5c`](paritytech/jsonrpc@2b47a5c) Use parity-ws-rs from crates.io ([rust-lang#361](https://github-redirect.dependabot.com/paritytech/jsonrpc/issues/361))
- [`8160eb5`](paritytech/jsonrpc@8160eb5) ci: bring appveyor back ([rust-lang#364](https://github-redirect.dependabot.com/paritytech/jsonrpc/issues/364))
- [`80205d4`](paritytech/jsonrpc@80205d4) Support multiple trailing arguments ([rust-lang#365](https://github-redirect.dependabot.com/paritytech/jsonrpc/issues/365))
- [`ec5249e`](paritytech/jsonrpc@ec5249e) Use procedural macros  ([rust-lang#340](https://github-redirect.dependabot.com/paritytech/jsonrpc/issues/340))
- [`789c74d`](paritytech/jsonrpc@789c74d) Derive Clone for all core types::* ([rust-lang#359](https://github-redirect.dependabot.com/paritytech/jsonrpc/issues/359))
- [`16ed9f5`](paritytech/jsonrpc@16ed9f5) Fix tokio deprecation warnings ([rust-lang#358](https://github-redirect.dependabot.com/paritytech/jsonrpc/issues/358))
- Additional commits viewable in [compare view](paritytech/jsonrpc@v9.0.0...v10.0.1)
</details>
<br />

[![Dependabot compatibility score](https://api.dependabot.com/badges/compatibility_score?dependency-name=jsonrpc-core&package-manager=cargo&previous-version=9.0.0&new-version=10.0.1)](https://dependabot.com/compatibility-score.html?dependency-name=jsonrpc-core&package-manager=cargo&previous-version=9.0.0&new-version=10.0.1)

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot ignore this [patch|minor|major] version` will close this PR and stop Dependabot creating any more for this minor/major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
- `@dependabot badge me` will comment on this PR with code to add a "Dependabot enabled" badge to your readme

Additionally, you can set the following in the `.dependabot/config.yml` file in this repo:
- Update frequency (including time of day and day of week)
- Automerge options (never/patch/minor, and dev/runtime dependencies)
- Pull request limits (per update run and/or open at any time)
- Out-of-range updates (receive only lockfile updates, if desired)
- Security updates (receive only security updates, if desired)

Finally, you can contact us by mentioning @dependabot.

</details>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

10 participants