Skip to content

Commit

Permalink
Convert to pyproject.toml for project informaiton
Browse files Browse the repository at this point in the history
  • Loading branch information
jmahlik committed Sep 20, 2023
1 parent 3cbb9e5 commit 22be47e
Show file tree
Hide file tree
Showing 5 changed files with 64 additions and 87 deletions.
1 change: 1 addition & 0 deletions docs/sources/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ The CHANGELOG for the current development version is available at
- Changed the signature of the `LinearRegression` model of sklearn in the test removing the `normalize` parameter as it is deprecated. ([#1036](https://github.com/rasbt/mlxtend/issues/1036))
- Add `pyproject.toml` to support PEP 518 builds
- Fixed installation from sdist failing
- Converted configuration to `pyproject.toml`

##### New Features and Enhancements

Expand Down
15 changes: 10 additions & 5 deletions docs/sources/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -446,18 +446,23 @@ Consider deploying the package to the PyPI test server first. The setup instruct
**First**, install Twine if you don't have it already installed. E.g., use the following to install all recommended packages:

```bash
$ conda install wheel twine setuptools
$ python -m pip install twine build
```


**Second**, create the binaries
**Second**, create the distribution. This by default creates an sdist and wheel
in the ``./dist`` directory.

```bash
$ python setup.py sdist
$ python -m build
```

Install the wheel and sdist to make sure they work.
The distributions file names will change with each version.

```bash
$ python setup.py bdist_wheel --universal
python -m pip install ./dist/mlxtend-0.23.0.dev0.tar.gz --force-reinstall
python -m pip install ./dist/mlxtend-0.23.0.dev0-py3-none-any.whl --force-reinstall
python -m pip uninstall mlxtend
```

**Third**, upload the packages to the test server:
Expand Down
53 changes: 53 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,56 @@ requires = [
"setuptools >= 59.0.0",
]
build-backend = "setuptools.build_meta"

[project]
name = "mlxtend"
authors = [
{name = "Sebastian Raschka", email = "[email protected]"}
]
description="Machine Learning Library Extensions"
dynamic = ["version", "dependencies"]
license= {text = "BSD 3-Clause"}
readme = "README.md"
classifiers=[
"License :: OSI Approved :: BSD License",
"Development Status :: 5 - Production/Stable",
"Operating System :: Microsoft :: Windows",
"Operating System :: POSIX",
"Operating System :: Unix",
"Operating System :: MacOS",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Topic :: Scientific/Engineering",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Scientific/Engineering :: Information Analysis",
"Topic :: Scientific/Engineering :: Image Recognition",
]

[project.optional-dependencies]
testing = ["pytest"]
docs = ["mkdocs"]

[project.urls]
Homepage = "https://github.com/rasbt/mlxtend"
Documentation = "https://rasbt.github.io/mlxtend"
Repository = "https://github.com/rasbt/mlxtend"

[tool.setuptools]
platforms = ["any"]

[tool.setuptools.dynamic]
version = {attr = "mlxtend.__version__"}
dependencies = {file = "requirements.txt"}

[tool.setuptools.package-data]
"*" = ["LICENSE-BSD3.txt", "LICENSE-CC-BY.txt", "README.md", "requirements.txt"]

[tool.pytest.ini_options]
norecursedirs = [
"plotting/*",
"image/*",
"build/",
]
5 changes: 0 additions & 5 deletions setup.cfg

This file was deleted.

77 changes: 0 additions & 77 deletions setup.py

This file was deleted.

0 comments on commit 22be47e

Please sign in to comment.