Issue #3086845 by jonathan1055, smustgrave: Module constraint checks fail incorrectly due to str_replace