[#4006] replace logger.warning
with warn_or_error
#4019
Merged
logger.warning
with warn_or_error
#4019