[v2 Bug] `dbt clean` misses destinations not configured anymore in `ai_provider`
Author: dbeatty10Created Sep 17, 2026Updated Sep 17, 2026
Labelstype:bugstatus:triageengine:v2triagebugv2
Is this a new bug in dbt v2.x compared to the latest version of dbt 1.x?
- I believe this is a new bug in dbt v2.x
- I have searched the existing issues and could not find a duplicate
Current Behavior
dbt clean misses destinations not configured anymore in ai_provider
Expected Behavior
dbt clean removes all skills that contain the relevant metadata indicating that it owned by dbt — even destinations not configured anymore in ai_provider.
Currently, there are only two agent skills folders: .agents/skills and .claude/skills
So this should be pretty easy to accomplish.
Steps To Reproduce
- Configure ‘ai_provider: claude’ under ‘flags:’ in ‘dbt_project.yml’
- Add a skill under the ‘skills’ subdirectory
- Run ‘dbt deps’ — see that it creates the skill under .claude/skills/
- Configure ‘ai_provider: wizard’
- Run ‘dbt clean’ — see that the skill under .claude/skills/ is still there
Relevant log output
Environment
- OS:
- CPU: (x86 or ARM)
- dbt distribution and version: (`dbt --version`)Which database adapter are you using?
No response
Is this a discrepancy vs. dbt 1.x?
- Yes — this works in dbt 1.x but not in dbt v2.x
Additional Context
No response
Source: dbt-labs/dbt-core