Skip to content

Conversation

@gounthar
Copy link
Collaborator

@gounthar gounthar commented Nov 14, 2025

Summary

Fixes the updatecli workflow failure by temporarily disabling the devcontainer dependency update pipeline that was blocking all updatecli runs.

Problem

After fixing the YAML syntax errors in PR #1843, updatecli started failing on the devcontainer dependency update configuration:

ERROR: could not find value for query "..." from file ".devcontainer/devcontainer.json"

Root Cause

The devcontainer.json file uses feature keys with special characters (dots, slashes, colons):

{
  "features": {
    "ghcr.io/devcontainers/features/docker-in-docker:2": {
      "version": "v27.0.3"
    },
    "ghcr.io/devcontainers/features/github-cli:1": {
      "version": "v2.83.1"
    }
  }
}

Updatecli cannot reliably target these nested fields regardless of approach:

  • JSON kind with JSONPath: Bracket notation fails to locate values
  • YAML kind with yamlpath: Complains about invalid characters
  • File kind with content blocks: Pattern matching is unreliable

Solution

Temporarily disable the problematic pipeline by:

  1. Renaming devcontainer.yaml to devcontainer.yaml.disabled
  2. Adding devcontainer.yaml.README.md explaining:
    • The technical issue
    • Manual update process
    • Potential future solutions
    • How to re-enable when fixed

This allows the other 7 updatecli pipelines to function correctly while documenting the limitation for future maintainers.

Impact

  • Fixes updatecli workflow on the weekly branch
  • Devcontainer Docker and GitHub CLI versions will need manual updates until a solution is found
  • All other dependency updates (Jenkins, Maven, Node, Debian, ssh-agent, etc.) continue to work automatically

Manual Update Process

Until resolved, devcontainer versions should be updated manually:

  1. Check https://github.com/moby/moby/releases for Docker
  2. Check https://github.com/cli/cli/releases for GitHub CLI
  3. Update .devcontainer/devcontainer.json
  4. Test in Codespaces

Future Solutions

  • Wait for updatecli to improve special character handling
  • Consider custom script outside updatecli
  • Restructure devcontainer.json (would require devcontainer spec changes)

Switch from file kind with regex patterns to json kind with JSONPath
queries for updating Docker and GitHub CLI versions in devcontainer.json.

The previous file-based approach failed because the search pattern matched
the feature name line, but the version field is on the next line. Using
json kind with JSONPath directly targets the correct fields.
@github-actions github-actions bot added the repo label Nov 14, 2025
JSON is valid YAML, and updatecli's yaml kind uses yq which handles
bracket notation better than the json kind's JSONPath implementation.
Use content parameter to identify the specific feature block, then apply
version pattern matching within that block. This avoids JSONPath/yamlpath
syntax issues with keys containing special characters.
Disable the devcontainer dependency update pipeline due to updatecli
limitations with JSON keys containing special characters (dots, slashes,
colons). Multiple approaches were attempted (json kind, yaml kind, file
kind with content blocks) but all failed.

Added README explaining the issue and manual update process until a
solution is found.
Updatecli loads all .yaml files in updatecli.d/ directory, including
.disabled files. Move the disabled devcontainer manifest and its README
to updatecli/disabled/ directory to prevent it from being loaded.
@gounthar gounthar force-pushed the fix-devcontainer-updatecli branch from ababeca to 87cb93c Compare November 14, 2025 10:33
@gounthar gounthar merged commit fbed4e9 into jenkins-docs:weekly Nov 14, 2025
4 checks passed
@gounthar gounthar deleted the fix-devcontainer-updatecli branch November 14, 2025 10:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant