fix(dry-run): commit no longer creates a real image; the interception… · docker/compose@6970069 · GitHub
Skip to content

Commit 6970069

Browse files
ndeloofglours
authored andcommitted
fix(dry-run): commit no longer creates a real image; the interception set becomes declarative
compose commit --dry-run delegated ContainerCommit to the real client and actually created the image. It now returns a dry-run ID without touching the engine. Auditing the rest of the client surface: 39 more mutating operations were delegated — none that compose itself issues (verified caller by caller), but any future code path reaching one would mutate the engine under --dry-run silently. They now refuse with an explicit error. The classification — read-only delegated / faked / refused — was only implied by a method's position under a comment; it is now declared in dryrunclient_test.go, which parses the client and fails on any method missing, misclassified, or new and unclassified: extending APIClient requires an explicit dry-run decision. The commit e2e scenario gains a --dry-run step asserting the image is NOT created (new ImageAbsent check). Epic #14074, B.7. Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
1 parent 73690c7 commit 6970069

4 files changed

Lines changed: 264 additions & 41 deletions

File tree

‎pkg/dryrun/dryrunclient.go‎

Lines changed: 90 additions & 41 deletions

0 commit comments

Comments
 (0)