vectordotdev/vector · error
No changelog fragments detected. If no changes necessitate…
Error message
No changelog fragments detected. If no changes necessitate user-facing explanations, add the 'no-changelog' label. Otherwise, add fragments to {CHANGELOG_DIR}/ (see {CHANGELOG_DIR}/README.md). What it means
The checker's primary gate is 'did this PR add at least one new changelog fragment?'. It diffs against the merge base filtering status 'A', excludes README.md, and bails when the resulting list is empty, pointing PR authors at the 'no-changelog' label or the fragments directory.
Solutions
- If the change needs no user-facing note, ensure the PR has the 'no-changelog' label in CI config/merge requirements
- Add a fragment: `vdev changelog new <type> <slug>` (it auto-stages) or create one in changelog.d/ and `git add` it
- Verify the fragment is staged and included in the diff: `git diff --name-only --diff-filter=A $(git merge-base HEAD main)`
Example fix
# before $ vdev check changelog-fragments # fails: no fragments added # after vdev changelog new enhancement add-retry-logic vdev check changelog-fragments
Defensive patterns
Strategy: validation
Validate before calling
const added = execSync(`git diff --name-only --diff-filter=A ${mergeBase} -- changelog.d`).toString().trim().split("\n").filter(f => f && path.basename(f) !== "README.md");
if (added.length === 0 && !hasNoChangelogLabel) addFragmentOrLabel(); Try / catch
try { runCheck(); } catch (e) { if (/No changelog fragments detected/.test(e.message)) { applyNoChangelogLabel(); } else throw e; } Prevention
- Create a fragment for every user-facing change before opening a PR
- Ensure `vdev changelog new` staging succeeded (check `git status`)
- Add the 'no-changelog' label when no fragment is warranted
When it happens
Trigger: Running `vdev check changelog-fragments` on a branch whose diff vs. merge base adds no fragment files under changelog.d/ (or only adds README.md, which is filtered out).
Common situations: Opening a PR with user-facing changes but no fragment; fragments only modified (status M), not added; fragments created but never `git add`-ed so they don't appear in `git diff --diff-filter=A`; wrong merge base (e.g. based on an outdated main).
Understand the failure class
Background: EmptyResultError / "no results found": when an API or scraper succeeds but returns zero rows — this error's family across 9 libraries.
Related errors
- duplicate upgrade-guide anchor '#
- invalid breaking fragment
- invalid breaking fragment
- invalid breaking fragment
- invalid fragment contents for
AI-assisted analysis of vectordotdev/vector@bdb87aeaa4 (2026-09-16).
Data as JSON: /api/errors/b257f7f9bce5580e.
Report an issue: GitHub.
Appendix: source
Thrown at vdev/src/commands/check/changelog_fragments.rs:52
let changelog_dir = repo_root.join(CHANGELOG_DIR);
if !changelog_dir.is_dir() {
bail!(
"No {CHANGELOG_DIR}/ directory at {}. Run this from the Vector repo root.",
repo_root.display()
);
}
// The gate "did the PR add a new fragment?" uses A (added) only — modifying an
// existing on-master fragment doesn't count toward the required changelog entry.
// Schema validation, on the other hand, must see M (modified) fragments too.
let is_real_fragment =
|p: &PathBuf| p.file_name().and_then(|s| s.to_str()) != Some("README.md");
let added_real: Vec<PathBuf> = diff_fragments(&self.merge_base, "A")?
.into_iter()
.filter(is_real_fragment)
.collect();
if added_real.is_empty() {
bail!(
"No changelog fragments detected. \
If no changes necessitate user-facing explanations, add the 'no-changelog' label. \
Otherwise, add fragments to {CHANGELOG_DIR}/ (see {CHANGELOG_DIR}/README.md)."
);
}
if added_real.len() > self.max_fragments {
bail!(
"Too many changelog fragments ({} > {}).",
added_real.len(),
self.max_fragments
);
}
// Every touched fragment (added or modified) must pass the schema check.
let modified: Vec<PathBuf> = diff_fragments(&self.merge_base, "M")?
.into_iter()
.filter(is_real_fragment)
.collect();View on GitHub (pinned to bdb87aeaa4)