Plotly PDF doc example not working

Hi plotly experts,

I’m trying to use the example from here: https://plot.ly/python/v3/pdf-reports/
but I get an error while trying to create the PDF at this line:

pisa_status = pisa.CreatePDF(
source_html, # the HTML to convert
dest=result_file) # file handle to recieve result

gaierror: [Errno 11004] getaddrinfo failed

Could someone help to get around this error?
Or is there any other way to generate PDFs of dash html layouts programatically?

Thanks in advance!

Package Versions:
dash 1.0.2
xhtml2pdf 0.2.3

I’m running dash on Windows.

three reasons why you should buy plotly pro: support open source, get great support, host your plots and dashboards online