File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2121 sys .exit (error )
2222
2323import os
24+ import shutil
2425from zipfile import ZipFile
2526
2627from setuptools import setup , find_packages , Extension
@@ -115,6 +116,16 @@ def build_extensions(self):
115116
116117
117118def _download_jquery_to (dest ):
119+ if os .path .exists (os .path .join (dest , "jquery-ui-1.12.1" )):
120+ return
121+
122+ # If we are installing from an sdist, use the already downloaded jquery-ui
123+ sdist_src = os .path .join (
124+ "lib/matplotlib/backends/web_backend" , "jquery-ui-1.12.1" )
125+ if os .path .exists (sdist_src ):
126+ shutil .copytree (sdist_src , os .path .join (dest , "jquery-ui-1.12.1" ))
127+ return
128+
118129 # Note: When bumping the jquery-ui version, also update the versions in
119130 # single_figure.html and all_figures.html.
120131 url = "https://jqueryui.com/resources/download/jquery-ui-1.12.1.zip"
You can’t perform that action at this time.
0 commit comments