Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Don't redownload jquery when installing from an sdist #14915

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 5, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions 11 setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
sys.exit(error)

import os
import shutil
from zipfile import ZipFile

from setuptools import setup, find_packages, Extension
Expand Down Expand Up @@ -115,6 +116,16 @@ def build_extensions(self):


def _download_jquery_to(dest):
if os.path.exists(os.path.join(dest, "jquery-ui-1.12.1")):
return

# If we are installing from an sdist, use the already downloaded jquery-ui
sdist_src = os.path.join(
"lib/matplotlib/backends/web_backend", "jquery-ui-1.12.1")
if os.path.exists(sdist_src):
shutil.copytree(sdist_src, os.path.join(dest, "jquery-ui-1.12.1"))
return

# Note: When bumping the jquery-ui version, also update the versions in
# single_figure.html and all_figures.html.
url = "https://jqueryui.com/resources/download/jquery-ui-1.12.1.zip"
Expand Down
Morty Proxy This is a proxified and sanitized view of the page, visit original site.