You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug][Azure DevOps] project_mapping missing repos scope when entities empty or CROSS-only #8749
I had searched in the issues and found no similar issues.
What happened
In backend/plugins/azuredevops_go/api/blueprint_v200.go, the makeScopeV200 function has two issues:
It does not default scopeConfig.Entities to plugin.DOMAIN_TYPES when entities are empty. When a blueprint is created without specifying entities (common in the UI), no scopes are generated and project_mapping ends up with no rows.
The repo scope condition checks for DOMAIN_TYPE_CODE_REVIEW and DOMAIN_TYPE_CODE but not DOMAIN_TYPE_CROSS. This means that when only CROSS is selected, the repo scope is missing from project_mapping, which breaks DORA metrics that depend on the cross-domain join.
These are the same bugs that were fixed for GitLab in #8743 (which fixed #8742).
What do you expect to happen
When scopeConfig.Entities is empty, it should default to plugin.DOMAIN_TYPES so that all domain scopes are created in project_mapping.
The repo scope condition should also check for DOMAIN_TYPE_CROSS, consistent with GitLab and Bitbucket.
How to reproduce
Create an Azure DevOps connection and configure a blueprint without specifying entities (leave entities empty)
Run the blueprint
Check the project_mapping table - no rows are created for this scope
Or:
Configure an Azure DevOps blueprint with only CROSS entity
Run the blueprint
Check project_mapping - the repo scope is missing
Anything else
Follow-up from #8742 / #8743. The fix applies the same pattern used in GitLab.
Thanks for filing this! Your analysis is correct — the Azure DevOps makeScopeV200 function in blueprint_v200.go is missing the same two fixes that were applied to GitLab in PR #8743.
The fix should follow the same pattern:
Default empty scopeConfig.Entities to plugin.DOMAIN_TYPES at the start of the function
Add plugin.DOMAIN_TYPE_CROSS to the repo scope conditions (for both ADO and non-ADO repository checks)
Note: Issue #8742 also identified Bitbucket as having the same problem, so you may want to check if that needs a similar fix as well.
Activity
dosubot commentedon Mar 3, 2026
Thanks for filing this! Your analysis is correct — the Azure DevOps
makeScopeV200function inblueprint_v200.gois missing the same two fixes that were applied to GitLab in PR #8743.The fix should follow the same pattern:
scopeConfig.Entitiestoplugin.DOMAIN_TYPESat the start of the functionplugin.DOMAIN_TYPE_CROSSto the repo scope conditions (for both ADO and non-ADO repository checks)Note: Issue #8742 also identified Bitbucket as having the same problem, so you may want to check if that needs a similar fix as well.
To reply, just mention @dosu.
Docs are dead. Just use Dosu.
fix(azuredevops): default empty entities and add CROSS to repo scope …
fix(azuredevops): default empty entities and add CROSS to repo scope …
fix(azuredevops): default empty entities and add CROSS to repo scope …
feat: GitHub App token refresh (#8746)
fix(azuredevops): default empty entities and add CROSS to repo scope …
feat: GitHub App token refresh (apache#8746)
fix(azuredevops): default empty entities and add CROSS to repo scope …
feat: GitHub App token refresh (apache#8746)
fix(azuredevops): default empty entities and add CROSS to repo scope …
fix: Copilot plugin - add backfill time window to ensure data consist…
Sync upstream Apache DevLake (v1.0.3-beta9 → beta15) (#22)