From 461f27e8098e4361b0ccbeeb6936168126927d5b Mon Sep 17 00:00:00 2001 From: Rens Date: Tue, 24 Jun 2025 09:27:38 +0200 Subject: [PATCH] Update package build process and add 'build' to requirements --- nbdev/release.py | 2 +- nbs/api/18_release.ipynb | 2 +- settings.ini | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/nbdev/release.py b/nbdev/release.py index 9a31f1949..747498765 100644 --- a/nbdev/release.py +++ b/nbdev/release.py @@ -316,7 +316,7 @@ def release_pypi( ): "Create and upload Python package to PyPI" _dir = get_config().lib_path.parent - system(f'cd {_dir} && rm -rf dist build && python setup.py sdist bdist_wheel') + system(f'cd {_dir} && rm -rf dist build && python -m build') system(f'twine upload --repository {repository} {_dir}/dist/*') # %% ../nbs/api/18_release.ipynb diff --git a/nbs/api/18_release.ipynb b/nbs/api/18_release.ipynb index 0fde492f1..98097d501 100644 --- a/nbs/api/18_release.ipynb +++ b/nbs/api/18_release.ipynb @@ -749,7 +749,7 @@ "):\n", " \"Create and upload Python package to PyPI\"\n", " _dir = get_config().lib_path.parent\n", - " system(f'cd {_dir} && rm -rf dist build && python setup.py sdist bdist_wheel')\n", + " system(f'cd {_dir} && rm -rf dist build && python -m build')\n", " system(f'twine upload --repository {repository} {_dir}/dist/*')" ] }, diff --git a/settings.ini b/settings.ini index 535ff4b9c..4f3654e81 100644 --- a/settings.ini +++ b/settings.ini @@ -15,7 +15,7 @@ language = English custom_sidebar = True license = apache2 status = 5 -requirements = fastcore>=1.8.0 execnb>=0.1.12 astunparse ghapi>=1.0.3 watchdog asttokens setuptools +requirements = fastcore>=1.8.0 execnb>=0.1.12 astunparse ghapi>=1.0.3 watchdog asttokens setuptools build pip_requirements = PyYAML conda_requirements = pyyaml conda_user = fastai