Skip to content

Test: Introduce intentional VS build break for CI testing#16

Open
devin-ai-integration[bot] wants to merge 3 commits intomasterfrom
devin/1768098417-test-vs-build-break
Open

Test: Introduce intentional VS build break for CI testing#16
devin-ai-integration[bot] wants to merge 3 commits intomasterfrom
devin/1768098417-test-vs-build-break

Conversation

@devin-ai-integration
Copy link

@devin-ai-integration devin-ai-integration bot commented Jan 11, 2026

Why I did it

⚠️ TEST PR - DO NOT MERGE ⚠️

This PR demonstrates the full cycle of:

  1. Intentionally introducing errors in the VS (virtual switch) build
  2. Verifying the CI correctly detects and reports the errors
  3. Fixing the issues based solely on CI logs
Work item tracking
  • Microsoft ADO (number only): N/A - Test PR

How I did it

Step 1: Introduced intentional errors in VS-specific files:

  1. Makefile syntax error in platform/vs/docker-sonic-vs.mk:

    • Missing closing parenthesis in variable reference: $(NONEXISTENT_DEPENDENCY
  2. Invalid Dockerfile command in platform/vs/docker-sonic-vs/Dockerfile.j2:

    • Added RUN_INVALID_COMMAND this_will_fail before the FROM statement

Step 2: CI detected the error:

ERROR: failed to solve: no build stage in current context

Step 3: Fixed based on CI logs:

  • Removed the invalid Dockerfile command that was placed before the FROM statement
  • Removed the Makefile syntax error

How to verify it

  1. ✅ CI failed on the VS build with clear error message
  2. ✅ Fix was applied based on CI logs
  3. Wait for CI to pass on the fix commit

Which release branch to backport (provide reason below if selected)

N/A - Test PR, not for backporting

  • 202305
  • 202311
  • 202405
  • 202411
  • 202505
  • 202511

Tested branch (Please provide the tested image version)

N/A - Test PR

Description for the changelog

Test PR to verify VS build CI failure detection and fix workflow - DO NOT MERGE

Link to config_db schema for YANG module changes

N/A

A picture of a cute animal (not mandatory but encouraged)

🐛➡️🦋 (bug found and fixed!)


Link to Devin run: https://cisco-demo.devinenterprise.com/sessions/8ff2c8abda09472183a2ced384128eab
Requested by: Arthur Poon (@arthurkkp-cog)

Co-Authored-By: Arthur Poon <arthur.poon@windsurf.com>
@devin-ai-integration
Copy link
Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

Co-Authored-By: Arthur Poon <arthur.poon@windsurf.com>
@arthur-cog-sonic
Copy link
Owner

❌ Build Failed: vs

Build: #135 | Commit: 19f4834

⚠️ docker-sonic-vs.gz.log (1 errors, 81 lines total)

Errors found:

81:ERROR: failed to solve: no build stage in current context

Last 200 lines:

Build start time: Sun Jan 11 05:41:18 UTC 2026
[ REASON ] :      target/docker-sonic-vs.gz does not exist   NON-EXISTENT PREREQUISITES: docker-start target/docker-swss-layer-bookworm.gz-load 
[ FLAGS  FILE    ] : [vs amd64 bookworm] 
[ FLAGS  DEPENDS ] : [vs amd64 bookworm] 
[ FLAGS  DIFF    ] : [] 
Client: Docker Engine - Community
 Version:    24.0.2
 Context:    default
 Debug Mode: false
 Plugins:
  buildx: Docker Buildx (Docker Inc.)
    Version:  v0.10.5
    Path:     /usr/libexec/docker/cli-plugins/docker-buildx
  compose: Docker Compose (Docker Inc.)
    Version:  v2.18.1
    Path:     /usr/libexec/docker/cli-plugins/docker-compose

Server:
 Containers: 0
  Running: 0
  Paused: 0
  Stopped: 0
 Images: 1
 Server Version: 24.0.2
 Storage Driver: overlay2
  Backing Filesystem: extfs
  Supports d_type: true
  Using metacopy: false
  Native Overlay Diff: false
  userxattr: false
 Logging Driver: json-file
 Cgroup Driver: cgroupfs
 Cgroup Version: 2
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
 Swarm: inactive
 Runtimes: runc io.containerd.runc.v2
 Default Runtime: runc
 Init Binary: docker-init
 containerd version: 3dce8eb055cbb6872793272b4f20ed16117344f8
 runc version: v1.1.7-0-g860f061
 init version: de40ad0
 Security Options:
  seccomp
   Profile: builtin
  cgroupns
 Kernel Version: 6.8.0-1044-azure
 Operating System: Debian GNU/Linux 12 (bookworm)
 OSType: linux
 Architecture: x86_64
 CPUs: 8
 Total Memory: 31.34GiB
 Name: aeb62f2439c2
 ID: 49f41290-9f44-4c84-8c13-f6efcf4a2747
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 Experimental: true
 Insecure Registries:
  127.0.0.0/8
 Live Restore Enabled: false

WARNING: bridge-nf-call-iptables is disabled
WARNING: bridge-nf-call-ip6tables is disabled
#1 [internal] load .dockerignore
#1 transferring context: 2B done
#1 DONE 0.1s

#2 [internal] load build definition from Dockerfile
#2 transferring dockerfile: 11.32kB done
#2 DONE 0.1s
Dockerfile:8
--------------------
   6 |     ARG SONIC_VERSION_CACHE
   7 |     ARG SONIC_VERSION_CONTROL_COMPONENTS
   8 | >>> COPY ["buildinfo", "/usr/local/share/buildinfo"]
   9 |     COPY vcache/ /sonic/target/vcache/docker-sonic-vs
  10 |     RUN dpkg -i /usr/local/share/buildinfo/sonic-build-hooks_1.0_all.deb
--------------------
ERROR: failed to solve: no build stage in current context

🔍 1 error(s) found across 2 log file(s)

The CI failed with error:
  ERROR: failed to solve: no build stage in current context

This was caused by an invalid Dockerfile command (RUN_INVALID_COMMAND)
placed before the FROM statement. Also removed the Makefile syntax error
(missing closing parenthesis) that was added for testing.

Co-Authored-By: Arthur Poon <arthur.poon@windsurf.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant