Skip to content
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

Transition from using setup.py to pyproject.toml to specify project metadata #269

Merged
merged 16 commits into from
Feb 29, 2024
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ RUN mkdir /SDGym && \
mkdir /SDGym/sdgym && \

# Copy code
COPY setup.py README.md HISTORY.md MANIFEST.in LICENSE Makefile setup.cfg /SDGym/
COPY pyproject.toml README.md HISTORY.md MANIFEST.in LICENSE Makefile setup.cfg /SDGym/
COPY /sdgym/ /SDGym/sdgym

WORKDIR /SDGym
Expand Down
3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,7 @@ coverage: ## check code coverage quickly with the default Python

.PHONY: dist
dist: clean ## builds source and wheel package
python setup.py sdist
python setup.py bdist_wheel
python -m build --wheel --sdist
ls -l dist

.PHONY: publish-confirm
Expand Down
199 changes: 199 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,199 @@
[build-system]
requires = ['setuptools', 'wheel']
build-backend = 'setuptools.build_meta'

[project]
authors = [{ name = 'DataCebo, Inc.', email = '[email protected]' }]
classifiers = [
gsheni marked this conversation as resolved.
Show resolved Hide resolved
'Development Status :: 2 - Pre-Alpha',
'Intended Audience :: Developers',
'License :: Free for non-commercial use',
'Natural Language :: English',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Topic :: Scientific/Engineering :: Artificial Intelligence',
]
description = 'Benchmark tabular synthetic data generators using a variety of datasets'
keywords = ['machine learning', 'synthetic data generation', 'benchmark', 'generative models']
name = 'sdgym'
version = '0.7.1.dev0'
license = { text = 'BSL-1.1' }
requires-python = '>=3.8,<3.12'
readme = 'README.md'
urls = { 'Homepage' = 'https://github.com/sdv-dev/SDGym' }
gsheni marked this conversation as resolved.
Show resolved Hide resolved

gsheni marked this conversation as resolved.
Show resolved Hide resolved
dependencies = [
'appdirs>=1.3,<2',
'boto3>=1.15.0,<2',
'botocore>=1.18,<2',
'compress-pickle>=1.2.0,<3',
'humanfriendly>=8.2,<11',
"numpy>=1.20.0,<2;python_version<'3.10'",
"numpy>=1.23.3,<2;python_version>='3.10'",
"pandas>=1.1.3;python_version<'3.10'",
"pandas>=1.3.4;python_version>='3.10' and python_version<'3.11'",
"pandas>=1.5.0;python_version>='3.11'",
'psutil>=5.7,<6',
"scikit-learn>=0.24,<2;python_version<'3.10'",
"scikit-learn>=1.1.3,<2;python_version>='3.10'",
"scipy>=1.5.4,<2;python_version<'3.10'",
"scipy>=1.9.2,<2;python_version>='3.10'",
'tabulate>=0.8.3,<0.9',
"torch>=1.8.0;python_version<'3.10'",
"torch>=1.11.0;python_version>='3.10' and python_version<'3.11'",
"torch>=2.0.0;python_version>='3.11'",
'tqdm>=4.15,<5',
'XlsxWriter>=1.2.8,<4',
'rdt>=1.6.1,<2.0',
'sdmetrics>=0.11.0,<1.0',
'sdv>=1.3.0,<2',
]

[project.entry-points]
sdgym = { main = 'sdgym.cli.__main__:main' }

[project.optional-dependencies]

gsheni marked this conversation as resolved.
Show resolved Hide resolved
dask = ['dask', 'distributed']

test = [
'pytest>=3.4.2',
'pytest-cov>=2.6.0',
'jupyter>=1.0.0,<2',
'rundoc>=0.4.3,<0.5',
]

dev = [
# dask
'dask',
'distributed',

# test
'pytest>=3.4.2',
'pytest-cov>=2.6.0',
'jupyter>=1.0.0,<2',
'rundoc>=0.4.3,<0.5',

# general
'bumpversion>=0.5.3,<0.6',
'pip>=9.0.1',
'watchdog>=0.8.3,<0.11',

# style check
'flake8>=3.7.7,<4',
'flake8-absolute-import>=1.0,<2',
'flake8-builtins>=1.5.3,<1.6',
'flake8-comprehensions>=3.6.1,<3.7',
'flake8-debugger>=4.0.0,<4.1',
'flake8-docstrings>=1.5.0,<2',
'flake8-eradicate>=1.1.0,<1.2',
'flake8-fixme>=1.1.1,<1.2',
'flake8-mock>=0.3,<0.4',
'flake8-multiline-containers>=0.0.18,<0.1',
'flake8-mutable>=1.2.0,<1.3',
'flake8-expression-complexity>=0.0.9,<0.1',
'flake8-print>=4.0.0,<4.1',
'flake8-pytest-style>=1.5.0,<2',
'flake8-quotes>=3.3.0,<4',
'flake8-sfs>=0.0.3,<0.1',
'flake8-variables-names>=0.0.4,<0.1',
'dlint>=0.11.0,<0.12',
'isort>=4.3.4,<5',
'pandas-vet>=0.2.3,<0.3',
'pep8-naming>=0.12.1,<0.13',
'pydocstyle>=6.1.1,<6.2',

# fix style issues
'autoflake>=1.1,<2',
'autopep8>=1.4.3,<2',

# distribute on PyPI
'twine>=1.10.0,<4',
'wheel>=0.30.0',

# Advanced testing
'coverage>=4.5.1,<6',
'tox>=2.9.1,<4',
'importlib-metadata>=3.6',

# Invoke
'invoke',
]

all = [
# dask
'dask',
'distributed',

# test
'pytest>=3.4.2',
'pytest-cov>=2.6.0',
'jupyter>=1.0.0,<2',
'rundoc>=0.4.3,<0.5',
gsheni marked this conversation as resolved.
Show resolved Hide resolved

# general
'bumpversion>=0.5.3,<0.6',
'pip>=9.0.1',
'watchdog>=0.8.3,<0.11',

# style check
'flake8>=3.7.7,<4',
'flake8-absolute-import>=1.0,<2',
'flake8-builtins>=1.5.3,<1.6',
'flake8-comprehensions>=3.6.1,<3.7',
'flake8-debugger>=4.0.0,<4.1',
'flake8-docstrings>=1.5.0,<2',
'flake8-eradicate>=1.1.0,<1.2',
'flake8-fixme>=1.1.1,<1.2',
'flake8-mock>=0.3,<0.4',
'flake8-multiline-containers>=0.0.18,<0.1',
'flake8-mutable>=1.2.0,<1.3',
'flake8-expression-complexity>=0.0.9,<0.1',
'flake8-print>=4.0.0,<4.1',
'flake8-pytest-style>=1.5.0,<2',
'flake8-quotes>=3.3.0,<4',
'flake8-sfs>=0.0.3,<0.1',
'flake8-variables-names>=0.0.4,<0.1',
'dlint>=0.11.0,<0.12',
'isort>=4.3.4,<5',
'pandas-vet>=0.2.3,<0.3',
'pep8-naming>=0.12.1,<0.13',
'pydocstyle>=6.1.1,<6.2',

# fix style issues
'autoflake>=1.1,<2',
'autopep8>=1.4.3,<2',

# distribute on PyPI
'twine>=1.10.0,<4',
'wheel>=0.30.0',

# Advanced testing
'coverage>=4.5.1,<6',
'tox>=2.9.1,<4',
'importlib-metadata>=3.6',

# Invoke
'invoke',
]

[tool.setuptools]
include-package-data = true

[tool.setuptools.packages.find]
include = ['sdgym', 'sdgym.*']
namespaces = false

[tool.isort]
line_length = 99
lines_between_types = 0
multi_line_output = 4
not_skip = ['__init__.py']
use_parentheses = true

[tool.pydocstyle]
convention = 'google'
add-ignore = ['D107', 'D407', 'D417']
14 changes: 1 addition & 13 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ values =

[bumpversion:part:candidate]

[bumpversion:file:setup.py]
[bumpversion:file:pyproject.toml]
search = version='{current_version}'
replace = version='{new_version}'

Expand All @@ -36,17 +36,5 @@ extend-ignore = D105, # Missing docstring in magic method
PD005, # Use arithmetic operator instead of method
SFS3 # String literal formatting using f-string

[isort]
line_length = 99
lines_between_types = 0
multi_line_output = 4
not_skip = __init__.py
use_parentheses = True

[aliases]
test = pytest

[pydocstyle]
convention = google
add-ignore = D107, D407, D417

149 changes: 0 additions & 149 deletions setup.py

This file was deleted.

Loading
Loading