lukasjarosch / lukasjarosch/skipper

More precise error message for undefined template variables

Open
#60 1 comment 0 reactions 1 assignee View on GitHub

@lukasjarosch is already working on this.

Since Nov 30, 2022.

  • #61 by @lukasjarosch — open
topic/template type/feature
Dominant language
Go
Stars
12
Forks
3
PR merge metrics
No merged PRs in 30d

Description

**Is your feature request related to a problem? Please describe.**
If I reference an undeclared variable in my template, the error message is like `template 'example.filef' uses variables with undefined value on line 36 (line number is based on the rendered output and might not be accurate)`.

The line number is partially helpful, since it is only roughly in that line in the source file.

**Describe the solution you'd like**
In many cases it would help me if the variable that is missing would be mentioned.

For example the error message could look like `template 'example.filef' uses variable '.Inventory.foo.bar' with undefined value on line 36 (line number is based on the rendered output and might not be accurate)`

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.