backport #11575

#11575
/cc @spastorino