UnicodeDecodeError at /contracts/24546799/
'charmap' codec can't decode byte 0x98 in position 698: character maps to
tmp = BytesIO()
output = PyPDF2.PdfFileWriter()
pdf = open(path_pdf, 'r').read().encode("base64")
pdfOne = PyPDF2.PdfFileReader(pdf)
for page in range(pdfOne.getNumPages()):
output.addPage(pdfOne.getPage(page))
output.write(tmp)
os.remove(path_pdf)
print(tmp.read().decode('base64'))
{% for profile in profile_list %}
<svg width="250" height="250">
<pattern id="circle_avatar_pattern_{{ profile.id }}" width="100%" height="100%">
<image href="{{ profile.avatar.url }}" width="200" height="200" preserveAspectRatio="xMidYMin slice"></image>
</pattern>
<circle cx="125" cy="125" r="100" fill="url(#circle_avatar_pattern_{{ profile.id }})"></circle>
</svg>
<h2><a href="{{ profile.get_absolute_url }}">{{ profile.user }}</a></h2>
{% endfor %}
сейчас вот так