[CI]: TestImagePrune failure on EL9

未关闭
#4,249 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 3 天内回复

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
35/100
Issue 类型
缺陷
描述清晰度
需要澄清
活跃度
停滞
技术栈
go
领域
ci-cd, cli, testing-qa

调研方向

首先在 EL9 上复现 TestImagePrune,具体是 with_until/Wait_and_remove_until=10ms 用例,并检查 image_prune_test.go 第 239-250 行附近的代码。跟踪 image 在 pruning 后仍然列出的原因,然后确认该测试通过,且不会使其他 image-prune 用例出现回归。

由索引模型根据 Issue 内容生成。

描述

area/ci bug
Description

https://github.com/containerd/nerdctl/actions/runs/15053159687/job/42312653222?pr=4247


=== RUN   TestImagePrune/with_until/Wait_and_remove_until=10ms
    image_prune_test.go:250: 
        
        +============================================================================================================+
        | 🏗       | "TestImagePrune/with_until/Wait_and_remove_until=10ms": setup                                    |
        +============================================================================================================+
        
    image_prune_test.go:250: 
        
        +============================================================================================================+
        | 🚀      | "TestImagePrune/with_until/Wait_and_remove_until=10ms": starting test!                           |
        +============================================================================================================+
        | ⏳      | /tmp/TestImagePrunewith_untilWait_and_remove_until=10ms2821158703/001/3597bb21                   |
        +============================================================================================================+
        |         |                                                                                                  |
        +============================================================================================================+
        | config  | {                                                                                                |
        |         |   "BuildkitHost": "unix:///run/user/1001/buildkit-nerdctl-test/buildkitd.sock",                  |
        |         |   "Namespace": "nerdctl-test",                                                                   |
        |         |   "PrivateMode": ""                                                                              |
        |         | }                                                                                                |
        +============================================================================================================+
        | labels  | {}                                                                                               |
        +============================================================================================================+
        
    image_prune_test.go:250: 
        
        +------------------------------------------------------------------------------------------------------------+
        | ➡️      | ⚙️ /usr/local/bin/nerdctl image prune --force --all --filter until=10ms                          |
        +------------------------------------------------------------------------------------------------------------+
        | 🌱      | XDG_SESSION_TYPE=tty                                                                             |
        |         | HOME=/home/rootless                                                                              |
        |         | XDG_SESSION_CLASS=user                                                                           |
        |         | XDG_SESSION_ID=4                                                                                 |
        |         | XDG_RUNTIME_DIR=/run/user/1001                                                                   |
        |         | PATH=/usr/local/go/bin:/usr/local/go/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin |
        |         | :/bin:/usr/games:/usr/local/games:/snap/bin                                                      |
        |         | DOCKER_CONFIG=/tmp/TestImagePrunewith_untilWait_and_remove_until=10ms2821158703/003              |
        |         | NERDCTL_TOML=/tmp/TestImagePrunewith_untilWait_and_remove_until=10ms2821158703/003/nerdctl.toml  |
        +------------------------------------------------------------------------------------------------------------+
        | ⏰      | <1s (limit: 3m0s)                                                                                |
        +------------------------------------------------------------------------------------------------------------+
        | 📁      | /tmp/TestImagePrunewith_untilWait_and_remove_until=10ms2821158703/002                            |
        +------------------------------------------------------------------------------------------------------------+
        
    image_prune_test.go:250: 	
        
        <<<<<<<<<<<<<<<<<<<<
        	🖊️ Inspecting output (contains)
        	👀 testing:		``
        	❌ FAILED!		~= `testimageprune-with-until-7c219acd`
        >>>>>>>>>>>>>>>>>>>>
        
    image_prune_test.go:239: 
        
        +------------------------------------------------------------------------------------------------------------+
        | ➡️      | ⚙️ /usr/local/bin/nerdctl images                                                                 |
        +------------------------------------------------------------------------------------------------------------+
        |         | 🟢 REPOSITORY                            TAG       IMAGE ID        CREATED                   PLA |
        |         | TFORM       SIZE       BLOB SIZE                                                                 |
        |         | testimageprune-with-until-7c219acd    latest    8d8071fcf82d    Less than a second ago    linux/ |
        |         | amd64    5.865MB    2.814MB                                                                      |
        +------------------------------------------------------------------------------------------------------------+
        | 🌱      | XDG_SESSION_TYPE=tty                                                                             |
        |         | HOME=/home/rootless                                                                              |
        |         | XDG_SESSION_CLASS=user                                                                           |
        |         | XDG_SESSION_ID=4                                                                                 |
        |         | XDG_RUNTIME_DIR=/run/user/[1001](https://github.com/containerd/nerdctl/actions/runs/15053159687/job/42312653222?pr=4247#step:10:1002)                                                                   |
        |         | PATH=/usr/local/go/bin:/usr/local/go/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin |
        |         | :/bin:/usr/games:/usr/local/games:/snap/bin                                                      |
        |         | DOCKER_CONFIG=/tmp/TestImagePrunewith_untilWait_and_remove_until=10ms2821158703/003              |
        |         | NERDCTL_TOML=/tmp/TestImagePrunewith_untilWait_and_remove_until=10ms2821158703/003/nerdctl.toml  |
        +------------------------------------------------------------------------------------------------------------+
        | ⏰      | <1s (limit: 3m0s)                                                                                |
        +------------------------------------------------------------------------------------------------------------+
        | 📁      | /tmp/TestImagePrunewith_untilWait_and_remove_until=10ms2821158703/002                            |
        +------------------------------------------------------------------------------------------------------------+
        
    image_prune_test.go:240: assertion failed: strings.Contains(imgList, data.Labels().Get("imageID")) is true: REPOSITORY                            TAG       IMAGE ID        CREATED                   PLATFORM       SIZE       BLOB SIZE
        testimageprune-with-until-7c219acd    latest    8d8071fcf82d    Less than a second ago    linux/amd64    5.865MB    2.814MB
        %!(EXTRA string=)
--- FAIL: TestImagePrune/with_until/Wait_and_remove_until=10ms (1.08s)

Steps to reproduce the issue

Seen on CI

Describe the results you received and expected

Not fail

What version of nerdctl are you using?

main

Are you using a variant of nerdctl? (e.g., Rancher Desktop)

None

Host information

No response

主要语言
Go
星标
10.5k
派生
853
平均合并
6 天 14 小时
30 天内合并 PR
38

环境准备

  • 提供 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 没有贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

containerd/nerdctl 的其他 Issue

查看 containerd/nerdctl 的全部 Issue

相似的 Issue

更多 Go Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。