File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -1210,18 +1210,18 @@ def _read_old_header(self, first_char):
1210
1210
if tp in self .OLD_TYPE_MAPPING :
1211
1211
typlist .append (self .OLD_TYPE_MAPPING [tp ])
1212
1212
else :
1213
- typlist .append (tp - 127 ) # string
1213
+ typlist .append (tp - 127 ) # py2 string, py3 bytes
1214
1214
1215
1215
try :
1216
1216
self .typlist = [self .TYPE_MAP [typ ] for typ in typlist ]
1217
1217
except :
1218
1218
raise ValueError ("cannot convert stata types [{0}]"
1219
- .format (',' .join (typlist )))
1219
+ .format (',' .join (str ( x ) for x in typlist )))
1220
1220
try :
1221
1221
self .dtyplist = [self .DTYPE_MAP [typ ] for typ in typlist ]
1222
1222
except :
1223
1223
raise ValueError ("cannot convert stata dtypes [{0}]"
1224
- .format (',' .join (typlist )))
1224
+ .format (',' .join (str ( x ) for x in typlist )))
1225
1225
1226
1226
if self .format_version > 108 :
1227
1227
self .varlist = [self ._null_terminate (self .path_or_buf .read (33 ))
You can’t perform that action at this time.
0 commit comments