In python 3.8, windows 10 x64, pycairo 1.20.1:
import cairo
with cairo.PDFSurface("example2.pdf", 200, 200) as surface:
pass
surface = cairo.PDFSurface("example.pdf", 200, 200)
surface.finish()
The call with the context manager works, but the last line surface finish throws an out of memory error. This is now only possible to use the surface within the context manager for some reason ?
Does anyone have the same issue ?
Thank you