improved warning messages