Skip to content

Commit

Permalink
Update pyproject.toml (#76)
Browse files Browse the repository at this point in the history
* Update pyproject.toml
* Version to 2.0.4
* Remove dynamic version

---------

Co-authored-by: tommyod <tommy.odland>
  • Loading branch information
tommyod authored Sep 1, 2024
1 parent b6d4b25 commit c831be1
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 19 deletions.
15 changes: 5 additions & 10 deletions efficient_apriori/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@
Implementation of the Apriori algorithm.
"""

# We use semantic versioning
# See https://semver.org/
__version__ = "2.0.3"

import sys
import importlib.metadata
from efficient_apriori.apriori import apriori
from efficient_apriori.itemsets import itemsets_from_transactions
from efficient_apriori.rules import Rule, generate_rules_apriori

# We use semantic versioning
# See https://semver.org/
__version__ = importlib.metadata.version("efficient_apriori")

__all__ = ["apriori", "itemsets_from_transactions", "Rule", "generate_rules_apriori"]


Expand All @@ -25,8 +25,3 @@ def run_tests():

base, _ = os.path.split(__file__)
pytest.main(args=[base, "--doctest-modules"])


if (sys.version_info[0] < 3) or (sys.version_info[1] < 7):
msg = "The `efficient_apriori` package only works for Python 3.7+."
raise Exception(msg)
16 changes: 7 additions & 9 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
[build-system]
requires = ["setuptools","twine", "wheel","efficient_apriori"]
requires = ["setuptools", "wheel"]
build-backend = "setuptools.build_meta"

[project]
name = "efficient_apriori"
dynamic = ["readme","dependencies","version"]
version = "2.0.4"
dynamic = ["readme"]
description = " An efficient Python implementation of the Apriori algorithm."
license = {file = "LICENSE"}
authors = [
Expand All @@ -19,32 +20,29 @@ classifiers = [
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
]
requires-python = ">=3.7"
requires-python = ">=3.8"

[project.urls]
Source = "https://github.com/tommyod/Efficient-Apriori"
Homepage = "https://github.com/tommyod/Efficient-Apriori"
Documentation = "https://github.com/tommyod/Efficient-Apriori#readme"
Repository = "https://github.com/tommyod/Efficient-Apriori.git"

[tool.setuptools.dynamic]
version = {attr = "efficient_apriori.__version__"}
readme = { file = "README.md", content-type = "text/markdown"}
dependencies = {file = ["requirements.txt"]}

[tool.setuptools.packages.find]
where = ["efficient_apriori"]
exclude = ["contrib", "docs", "tests"]
namespaces = false

[tool.setuptools.package-data]
"*" = ["templates/*", "*.tex", "*.html"]

[tool.pytest.ini_options]
testpaths = ["efficient_apriori/tests"]
addopts = "-v -ra -q"
log_cli = true
log_cli_level = "INFO"
log_format = "%(asctime)s %(levelname)s %(message)s"
log_date_format = "%Y-%m-%d %H:%M:%S"
minversion = "3.6"
minversion = "3.7"
filterwarnings = "ignore"
norecursedirs = "docs"

0 comments on commit c831be1

Please sign in to comment.