jdx/mise · warning · eyre::Report
"{path_raw}".{id}: block and source are mutually exclusive,
Error message
"{path_raw}".{id}: block and source are mutually exclusive, ignoring entry What it means
A block edit's content can come from either the inline block = string or an external file via source =, but not both — there would be no rule for which content wins. The entry is warned about and skipped when both are set.
Source
Thrown at src/system/edits.rs:256
},
EditTomlEntry::Table(table) => table,
};
let is_block = entry.block.is_some() || entry.source.is_some();
let op = match (&is_block, &entry.line) {
(true, Some(_)) => {
bail!(
"\"{path_raw}\".{id}: block/source and line are mutually exclusive, ignoring entry"
)
}
(false, None) => {
bail!(
"\"{path_raw}\".{id}: no recognized operation (block, source, or line), ignoring entry"
)
}
(true, None) => {
let source = match (entry.block, entry.source) {
(Some(_), Some(_)) => {
bail!(
"\"{path_raw}\".{id}: block and source are mutually exclusive, ignoring entry"
)
}
(Some(inline), None) => BlockSource::Inline(inline),
(None, Some(src)) => {
let src = file::replace_path(&src);
BlockSource::File(if src.is_relative() {
base.join(src)
} else {
src
})
}
(None, None) => unreachable!("is_block"),
};
let template = match entry.template.as_deref() {
None => false,
Some("tera") => true,
Some(other) => {View on GitHub (pinned to 9dcfcaa0dc)
Solutions
- Keep source = and remove block = (recommended when content grows or is templated)
- Or keep block = and remove source = for short inline content
Example fix
# before
[dotfiles]
"~/.zshrc/aliases" = { block = 'alias ll=ls -la', source = "snippets/aliases.sh" }
# after
[dotfiles]
"~/.zshrc/aliases" = { source = "snippets/aliases.sh" } Defensive patterns
Strategy: validation
Validate before calling
python3 - <<'EOF'
import tomllib
for key, v in tomllib.load(open('mise.toml','rb')).get('dotfiles', {}).items():
if isinstance(v, dict):
assert not ('block' in v and 'source' in v), f'block and source both set: {key}'
EOF Prevention
- Migrating inline block to source? Delete block in the same edit
- There is no fallback semantics — exactly one content source per entry
When it happens
Trigger: An entry like { block = 'alias ll=ls', source = "snippets/aliases.sh" } in [dotfiles].
Common situations: Moving from inline to file-backed content and forgetting to delete block; copy-paste merging two example entries; intent to provide a fallback content (not supported — deliberately no fallback semantics).
Related errors
- "{path_raw}".{id}: block/source and line are mutually exclus
- path "{path_raw}" must be absolute or start with ~/, ignorin
- "{path_raw}".{id:?}: ids may only contain letters, digits, '
- "{path_raw}".{id}: no recognized operation (block, source, o
- "{path_raw}".{id}: unknown template engine '{other}' (expect
AI-assisted analysis of jdx/mise@9dcfcaa0dc (2026-08-17).
Data as JSON: /api/errors/894f6f81e8099c42.
Report an issue: GitHub.