revert #5962 and #5806 for TCK compatibility