fix(agent/agentcontainers): filter out "is test run" devcontainers (#18568)

This commit is contained in:
Mathias Fredriksson
2025-06-25 11:06:20 +00:00
committed by GitHub
parent 42fd1c1291
commit 434b54657a
3 changed files with 31 additions and 1 deletions
+2 -1
View File
@@ -591,7 +591,8 @@ func (api *API) processUpdatedContainersLocked(ctx context.Context, updated code
slog.F("config_file", configFile),
)
if len(api.containerLabelIncludeFilter) > 0 {
// Filter out devcontainer tests, unless explicitly set in include filters.
if len(api.containerLabelIncludeFilter) > 0 || container.Labels[DevcontainerIsTestRunLabel] == "true" {
var ok bool
for label, value := range api.containerLabelIncludeFilter {
if v, found := container.Labels[label]; found && v == value {