---
title: "U7008: Invalid `ita.una` or `itaty.una`"
url: https://una-lang.org/en/docs/errors/U7008/
release: v0.4.0
source: https://github.com/una-lang/una/blob/v0.4.0/crates/una-explain/explain/U7008.md
---

# U7008: Invalid `ita.una` or `itaty.una`

`ita.una` or `itaty.una` holds an error. U7008 reports it at its line.

## Why Una rejects it

From edition `0.4`, a package describes itself in `ita.una`, and a workspace in `itaty.una` (ADR 0122, `spec/30`). Both are written in Una's own lexical syntax, by a closed grammar: a head `ita <name>` with its `version` and `edition` lines, then sections in a fixed order (`sources`, `needs`, `replace`, `trust`, `labels`, `trusted`, `escapes`, `boundaries`, `contracts`, `run`, `drive`, `serve`). Nothing in them is evaluated: there are no expressions, no interpolation and no includes.

U7008 reports, at its line:

- a syntax error,
- an unknown, repeated or misplaced line or section,
- a value of the wrong form or out of range,
- an edition before `0.4`,
- a directory that holds both `ita.una` and `una.toml`,
- a reserved local name,
- a `from git` origin,
- a `foreign` section or grant,
- an invalid limit line under a grant (a form other than `at most <n> per second`, `minute` or `hour`, `at most <n> at once` and `waiting at most <n>`, a count below 1 or above 2147483647, a limit under a grant other than `http`, or a kind of limit given twice; ADR 0117 rule 8, `spec/27 §9`),
- every error that `una.toml` reports as U7002 for the setting it corresponds to, and
- a `requires`, or a refined parameter or result type, on `handle` or `on_stop` of the module a `serve` section names, or on `init`, `step` or `on_stop` of the module a `drive` section names, a precondition that no call of the host establishes (`spec/31 §7`, `spec/26 §2`).

For a `drive` module, a refinement inside a type argument counts too, as in `step(edit state: Option[Pos], input: Tick)` with `kind Pos = Int where it > 0`: the host hands the state on by its type without its refinements.

## The repair at a glance

`ita.una`

```diff
  ita demo
-   version 0.1
+   version 0.1.0
    edition 0.4
```

## Failing example

`ita.una`

```una
ita demo
  version 0.1
  edition 0.4
```

`ita.lock`

```una
lock 1

solver
  encoding "una-smt-1"
  name "z3"
  version "5.1.0"
  logic "QF_UFLIA"
  steps 5000000
  seed 0
```

`src/demo.una`

```una
module demo

pub one() -> Int = 1
```

## Fixed example

`ita.una`

```una
ita demo
  version 0.1.0
  edition 0.4
```

`ita.lock`

```una
lock 1

solver
  encoding "una-smt-1"
  name "z3"
  version "5.1.0"
  logic "QF_UFLIA"
  steps 5000000
  seed 0
```

`src/demo.una`

```una
module demo

pub one() -> Int = 1
```
