Tya v0.55 Release Notes

Status: shipped. tya version reports 0.55.0 and ROADMAP.md carries the matching Released entry.

TL;DR

v0.55 makes tya lint ready for CI use:

The language surface is unchanged from v0.54.

What’s new

Per-line opt-out comments

# tya-lint-ignore: TYAL0001
tmp = 42                       # silences the unused-local finding

guard = false  # tya-lint-ignore   # silences every finding on this line

# tya-lint-ignore with no code list is a wildcard; a comma- separated : CODE list scopes the suppression. Inline comments target the same line, full-line comments target the next statement.

--format=json

$ tya lint --format=json src/
{
  "version": "0.55.0",
  "findings": [
    {
      "path": "src/foo.tya",
      "line": 12,
      "col": 3,
      "code": "TYAL0001",
      "message": "unused local \"tmp\"",
      "autofixable": true
    }
  ]
}

Findings are sorted by (path, line, col, code). Empty runs emit "findings": []. Exit codes are unchanged (0 clean / 1 findings / 2 error).

TYAL0002 dead code after return / raise

greet = ->
  return 1
  print("unreachable")   # TYAL0002 dead code after return

The rule fires inside every block (function bodies, if arms, while / for bodies, try / catch, match cases). It is warning-only (no autofix) — removing dead code is a human judgement call.

--fix autofix for TYAL0003

# before
if true
  print("hi")

# after `tya lint --fix`
print("hi")

--fix runs in two passes: first TYAL0003 unwrap-if (which shifts source positions), then TYAL0001 line-delete on the re-lexed source. Each pass writes the file in place.

Compatibility

Tooling

Next