-
Notifications
You must be signed in to change notification settings - Fork 18.7k
Return error if basename is expanded to blank #37396
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Return error if basename is expanded to blank #37396
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
Looking good; testing with empty values; both with a docker build --no-cache -<<'EOF'
ARG SOMETHING
ARG ALPINE
FROM ${SOMETHING} as builder
# No actual build steps, just copying
FROM ${ALPINE}
EXPOSE 8080
EOF
With docker build --no-cache -<<'EOF'
ARG SOMETHING
ARG ALPINE
FROM ${SOMETHING}:latest as builder
# No actual build steps, just copying
FROM ${ALPINE}:latest
EXPOSE 8080
EOF
|
Wondering if we already have a test covering the "with |
Also; janky failure is not related; tracked through #32673
restarting, but all other tests were green |
Codecov Report
@@ Coverage Diff @@
## master #37396 +/- ##
=========================================
Coverage ? 34.99%
=========================================
Files ? 610
Lines ? 44883
Branches ? 0
=========================================
Hits ? 15708
Misses ? 27060
Partials ? 2115 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
I think @tonistiigi had some questions about this; @tonistiigi PTAL |
The real reason why the error didn't appear seems to be that empty string is reused to mean moby/daemon/images/image_builder.go Line 171 in 328c089
|
Fix: moby#37325 Signed-off-by: Yuichiro Kaneko <spiketeika@gmail.com>
dc2440c
to
c9542d3
Compare
I added comment. Can you review again when you have a chance? |
Fix: #37325
Signed-off-by: Yuichiro Kaneko spiketeika@gmail.com