# tar_order

> Tar entries are not in strictly ascending path-byte order, or a path repeats.

Tar entries are not in strictly ascending path-byte order, or a path repeats.

| | |
| --- | --- |
| Kind | Build or validation problem |
| Reported by | Archive validation (registry, room hosts, disko publish) |
| `disko` exit code | 1 (problems) |

The tar entries are not sorted in strictly ascending order by their path
bytes, or the same path appears twice. The fixed order is part of what makes
an archive reproducible.

## Why it happens

Archive validation reports this code: the registry on upload, and room hosts
before loading. `disko publish` sorts entries itself. Other tools write
entries in directory-listing order, or append a changed file a second time.

## Wrong

```text
src/main.js
game.json
art/puck.png
```

## Right

```text
art/puck.png
game.json
src/main.js
```

Build the archive with `disko publish --dry-run --out release.tgz` instead of
by hand.

## See also

- [Publish a release](/get-started/publish)
- [`tar_header_not_canonical`](/errors/tar_header_not_canonical)
