Closes #18174 @smarocchi @ax3l @svenevs The error message in #18174 isn't great, but I'm hoping that #18127 will improve that.