Remove some warning code for ancient python versions.