Skip to content

Commit dac4293

Browse files
committed
🐛 fix python3 compatibility
1 parent 1c8573d commit dac4293

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

pyexcel_xlsxr/messy_xlsx.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
DATE_1904_MATCHER = re.compile(b".*?(<workbookPr.*?\/>).*?", re.MULTILINE)
2323
#"xmlns:x14ac="http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac"
2424
#But it not used for now
25-
X14AC_NAMESPACE = 'xmlns:x14ac="http://not.used.com/"'
25+
X14AC_NAMESPACE = b'xmlns:x14ac="http://not.used.com/"'
2626

2727
# see also ruby-roo lib at: http://github.com/hmcgowan/roo
2828
FORMATS = {
@@ -182,9 +182,9 @@ def __repr__(self):
182182

183183

184184
def parse_row(row_xml_string, book):
185-
if "x14ac" in row_xml_string:
185+
if b"x14ac" in row_xml_string:
186186
row_xml_string = row_xml_string.replace(
187-
"<row", "<row %s" % X14AC_NAMESPACE
187+
b"<row", (b"<row " + X14AC_NAMESPACE)
188188
)
189189
partial = io.BytesIO(row_xml_string)
190190
cells = []

0 commit comments

Comments
 (0)