buildkit icon indicating copy to clipboard operation
buildkit copied to clipboard

TestUndeclaredArg fails on arm64

Open tonistiigi opened this issue 8 months ago • 0 comments

=== FAIL: frontend/dockerfile TestIntegration/TestUndeclaredArg/worker=oci-rootless/frontend=gateway/warntype=progress#05 (1.14s)
    dockerfile_lint_test.go:1076: 
        	Error Trace:	/src/frontend/dockerfile/dockerfile_lint_test.go:1037
        	            				/src/frontend/dockerfile/dockerfile_lint_test.go:1076
        	Error:      	Not equal: 
        	            	expected: 1
        	            	actual  : 2
        	Test:       	TestIntegration/TestUndeclaredArg/worker=oci-rootless/frontend=gateway/warntype=progress#05
        --- FAIL: TestIntegration/TestUndeclaredArg/worker=oci-rootless/frontend=gateway/warntype=progress#05 (1.14s)

This happens because additional base image platform warning is also returned:

    dockerfile_lint_test.go:1086: warning: Lint Rule 'UndefinedArgInFrom': FROM argument 'version' is not declared (line 3) [FROM command must use declared ARGs]
    dockerfile_lint_test.go:1086: warning: Lint Rule 'InvalidBaseImagePlatform': Base image busybox:latest was pulled with platform "linux/arm64", expected "linux/amd64" for current build (line 3) [Base image platform does not match expected target platform]

Probably related to mirrors in the test only pulling the local arch image.

Note that weirdly the "unmarshal" version on the same test passes fine. This is also worth investigation to understand the reason behind it.

tonistiigi avatar Jun 06 '24 22:06 tonistiigi