server: project Skills from active virtual config

This commit is contained in:
2026-08-14 11:55:33 +09:00
parent ad0f6c68d5
commit 6446eb1302
7 changed files with 737 additions and 688 deletions
@@ -40,7 +40,6 @@ impl WorkspaceConfigSchemaProvider for ProfileConfigSchemaProvider {
}
#[derive(Debug, Clone, Deserialize)]
#[serde(deny_unknown_fields)]
struct VirtualProfileConfig {
profile: VirtualProfileSection,
}
@@ -72,9 +71,14 @@ pub fn project_profiles_from_workspace_config(
workspace_id: &str,
state: &WorkspaceConfigState,
) -> Result<ProfileConfigProjection> {
let schema = ProfileConfigSchemaProvider.contribution()?;
let bundle = config_source::WorkspaceConfigSchemaBundle::compose([schema])
.map_err(|error| Error::Config(error.to_string()))?;
let bundle = if state.contract.schema_bundle.contributions.is_empty() {
config_source::WorkspaceConfigSchemaBundle::compose([
ProfileConfigSchemaProvider.contribution()?
])
.map_err(|error| Error::Config(error.to_string()))?
} else {
state.contract.schema_bundle.clone()
};
let evaluation = evaluate_workspace_config_state(state, bundle)?;
if evaluation.projection_digest != state.projection_digest
&& state