From 30861612877611a3f8aa5cb6f3ff738a7e9e8207 Mon Sep 17 00:00:00 2001 From: mahendrapaipuri Date: Thu, 19 Oct 2023 09:06:19 +0200 Subject: [PATCH] build: Exclude tests in sdist to reduce size * See https://github.com/mwouts/jupytext/pull/1140/files#r1364945854 * Remove unnecessary env var in binder postbuild --- binder/postBuild | 2 +- pyproject.toml | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/binder/postBuild b/binder/postBuild index 81c03c8f9..0efabf83c 100644 --- a/binder/postBuild +++ b/binder/postBuild @@ -4,7 +4,7 @@ set -e # Install from sources # NB: If you want to use Jupytext on your binder, don't install it from source, # just add "jupytext" to your "binder/requirements.txt" instead. -HATCH_BUILD_HOOKS_ENABLE=true pip install . +pip install . mkdir -p ${HOME}/.jupyter/labconfig cp binder/labconfig/* ${HOME}/.jupyter/labconfig diff --git a/pyproject.toml b/pyproject.toml index 5078f3244..ab19a4a0a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -42,7 +42,7 @@ dynamic = ["version"] [project.urls] Homepage = "https://github.com/mwouts/jupytext" "Source Code" = "https://github.com/mwouts/jupytext" -Documentation = "https://jupytext.readthedocs.io/en/latest/index.html" +Documentation = "https://jupytext.readthedocs.io" [project.optional-dependencies] # Test related dependencies @@ -102,10 +102,12 @@ path = "src/jupytext/version.py" # Following config is related to JupyterLab extension [tool.hatch.build.targets.sdist] artifacts = ["jupyterlab/jupyterlab_jupytext/labextension"] +# Exclude tests (contains Notebooks that have a total size of ~8MB) to reduce sdist +# tarball. (See #1142) +exclude = ["tests", "**/.yarn", "**/node_modules"] [tool.hatch.build.targets.wheel] packages = ["src/jupytext", "src/jupytext_config", "jupyterlab/jupyterlab_jupytext"] -exclude = ["**/.yarn", "**/node_modules"] [tool.hatch.build.targets.wheel.shared-data] "jupyterlab/jupyter-config" = "etc/jupyter"