Black Lives Matter. Please consider donating to Black Girls Code today.

SVG and PDF formats not working with Python method py.image.get()?

I’m, not sure if this is the right place for this query. Sorry, if not:

I have an application that’s been happily generating graphs in SVG format for the last few months. Today it has started returning an error. On further investigation the plotly server is returning a HTTP 402 response.

As a very simple example, the following code succeeds with JPEG and PNG formats, but fails with SVG and PDF formats.

import plotly.plotly as py
fig = {‘data’: [{‘x’: [1, 2, 3], ‘y’: [3, 1, 5], ‘type’: ‘bar’}]}
py.image.get(fig, ‘svg’, scale=3)

Any ideas?! Has anything changed? Thanks in advance.

SOLVED - After checking the subscription conditions, it turns out SVG and PDF formats are restricted to paying users. Plotly must have just started enforcing this, as we’ve been using it for months without a paid account. We have just upgraded and now it’s working fine.