summaryrefslogtreecommitdiffstats
path: root/openbb_platform/obbject_extensions/charting/openbb_charting/core/backend.py
diff options
context:
space:
mode:
Diffstat (limited to 'openbb_platform/obbject_extensions/charting/openbb_charting/core/backend.py')
-rw-r--r--openbb_platform/obbject_extensions/charting/openbb_charting/core/backend.py13
1 files changed, 1 insertions, 12 deletions
diff --git a/openbb_platform/obbject_extensions/charting/openbb_charting/core/backend.py b/openbb_platform/obbject_extensions/charting/openbb_charting/core/backend.py
index fb2503afe86..e1031059789 100644
--- a/openbb_platform/obbject_extensions/charting/openbb_charting/core/backend.py
+++ b/openbb_platform/obbject_extensions/charting/openbb_charting/core/backend.py
@@ -18,8 +18,6 @@ import pandas as pd
import plotly.graph_objects as go
from openbb_core.env import Env
from packaging import version
-from reportlab.graphics import renderPDF
-from svglib.svglib import svg2rlg
if TYPE_CHECKING:
from openbb_core.app.model.charts.charting_settings import ChartingSettings
@@ -54,7 +52,7 @@ else:
JUPYTER_NOTEBOOK = True
PLOTS_CORE_PATH = Path(__file__).parent.resolve()
-PLOTLYJS_PATH = PLOTS_CORE_PATH / "assets" / "plotly-2.24.2.min.js"
+PLOTLYJS_PATH = PLOTS_CORE_PATH / "assets" / "plotly-2.32.0.min.js"
BACKEND = None
@@ -236,7 +234,6 @@ class Backend(PyWry):
async def process_image(self, export_image: Path):
"""Check if the image has been exported to the path."""
- pdf = export_image.suffix == ".pdf"
img_path = export_image.resolve()
checks = 0
@@ -246,15 +243,7 @@ class Backend(PyWry):
if checks > 50:
break
- if pdf:
- img_path = img_path.rename(img_path.with_suffix(".svg"))
-
if img_path.exists(): # noqa: SIM102
- if pdf:
- drawing = svg2rlg(img_path)
- img_path.unlink(missing_ok=True)
- renderPDF.drawToFile(drawing, str(export_image))
-
if self.charting_settings.plot_open_export:
if sys.platform == "win32":
os.startfile(export_image) # nosec: B606 # noqa: S606