Cherrypicked the other input wrapper commit