I am running into the following error while writing the value into a file. Can you please help me figure out what is the issue here and how to fix it?
row = 649
with open(r'\locdevBuild_veruild_ver.txt','r+') as f:
f.write(row)
print row
Error:
Traceback (most recent call last):
File "latest_rev.py", line 6, in <module>
f.write(row)
TypeError: expected a character buffer object
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…