Skip to content

Commit

Permalink
Move plotly.io import to local method to resolve python 3.6 circular …
Browse files Browse the repository at this point in the history
…import
  • Loading branch information
jonmmease committed Mar 5, 2021
1 parent 586be5c commit 624c30c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion repos/kaleido/py/kaleido/scopes/plotly.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
from __future__ import absolute_import
from kaleido.scopes.base import BaseScope, which
import plotly.io as pio
import base64
import os
from pathlib import Path
Expand Down Expand Up @@ -73,6 +72,7 @@ def scope_name(self):
return "plotly"

def _json_dumps(self, val):
import plotly.io as pio
return pio.to_json(val, validate=False, remove_uids=False)

def transform(self, figure, format=None, width=None, height=None, scale=None):
Expand Down

0 comments on commit 624c30c

Please sign in to comment.