# XO1308: release build while a workspace overrides modules

An xo.work workspace builds the modules it uses from their local directories, overriding the versions xo.mod requires. That is for development only: a release build (`xo build --release`, and `xo build --ci`) must build exactly what xo.mod and xo.lock pin, so it fails while a workspace overrides a required module, naming those modules. Build with `--workspace=off` (or XO_WORK=off) to ignore xo.work, or release the overridden modules, require their new versions, and run `xo mod tidy`. See decision 0086.

## Example

```xo
# xo.work: use ./api, use ./billing; api requires billing
xo build --release ./api
```

## Fix

```xo
xo build --release --workspace=off ./api
```

Run `xo explain XO1308` for this text in a terminal, or see
[section 10.6 of the specification](../../spec/core/#106-diagnostic-codes).

