# tasks: Show error for unknown \`ZED\_\` variables \(\#45621\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/9d5f0f5aaf1ae2b5f800d9a8efb77f61a50147be)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 9d5f0f5aaf1ae2b5f800d9a8efb77f61a50147be

Requested commit: 9d5f0f5aaf1ae2b5f800d9a8efb77f61a50147be

Commit: 9d5f0f5aaf1ae2b5f800d9a8efb77f61a50147be

Tree: dc56b9505dd79d21cf106dc75ad4a7781a651b1e

Author: Karl-Erik Enkelmann

Committer: GitHub

## Message

```
tasks: Show error for unknown `ZED_` variables (#45621)

Validate task variable names when the file is saved, immediately
displaying an error toast if any invalid `ZED_*` variables are found.
Valid tasks in the same file are still loaded and work normally.

- Add `task::task_template::TaskTemplate::unknown_variables()` to detect
  invalid `ZED_` variable names
- Add `project::ToastLink` struct and optional `link` field to
  `project::Event::Toast`
- Show documentation link in the error toast

Closes #23275

Release Notes:

- Fixed user-defined tasks with unresolved `ZED_*` variables being
silently omitted

---------

Co-authored-by: dino <dinojoaocosta@gmail.com>
```

## Parents

- [b74b1977d4634b78b4ed1be5d9c7e188c90e9827](https://git.cafe/gitcafe/zed/commit/b74b1977d4634b78b4ed1be5d9c7e188c90e9827?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/9d5f0f5aaf1ae2b5f800d9a8efb77f61a50147be?format=markdown)
