Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 1 addition & 5 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,7 @@ jobs:
with:
python-version: "3.12"
- name: Install build tools and doc build tools
run: |
pip install --upgrade "pip<24.1" "setuptools>=69.0.0,<=73.0.1"
# pip<24.1 because https://github.com/omry/omegaconf/pull/1195
# setuptools>=65.0.2 because https://github.com/pypa/setuptools/commit/d03da04e024ad4289342077eef6de40013630a44#diff-9ea6e1e3dde6d4a7e08c7c88eceed69ca745d0d2c779f8f85219b22266efff7fR1
# setuptools<=73.0.1 because https://github.com/pypa/setuptools/issues/4620
run: pip install --upgrade pip
- name: Install PyThaiNLP
run: pip install ".[docs]"
- name: Build sphinx documentation
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pypi-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
env:
SKLEARN_ALLOW_DEPRECATED_SKLEARN_PACKAGE_INSTALL: True
run: |
python -m pip install --upgrade "pip<24.1" setuptools
python -m pip install --upgrade pip
python -m pip install ".[compact]"
python -m nltk.downloader omw-1.4

Expand Down
7 changes: 1 addition & 6 deletions .github/workflows/unittest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ on:
- "pythainlp/**"
- "tests/**"
- "Makefile"
- "MANIFEST.in"
- "pyproject.toml"
pull_request:
branches:
Expand All @@ -33,7 +32,6 @@ on:
- "pythainlp/**"
- "tests/**"
- "Makefile"
- "MANIFEST.in"
- "pyproject.toml"

# Avoid duplicate runs for the same source branch and repository.
Expand Down Expand Up @@ -94,11 +92,8 @@ jobs:

- name: Install build tools
run: |
pip install --upgrade "pip<24.1" "setuptools>=69.0.0,<=73.0.1"
pip install --upgrade pip
pip install coverage coveralls
# pip<24.1 because https://github.com/omry/omegaconf/pull/1195
# setuptools>=65.0.2 because https://github.com/pypa/setuptools/commit/d03da04e024ad4289342077eef6de40013630a44#diff-9ea6e1e3dde6d4a7e08c7c88eceed69ca745d0d2c779f8f85219b22266efff7fR1
# setuptools<=73.0.1 because https://github.com/pypa/setuptools/issues/4620

- name: Install ICU (macOS)
if: startsWith(matrix.os, 'macos-')
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ The minimum requirement is now Python 3.9.
when the var is set; auto-downloads otherwise (#1306)
- Callers raise `FileNotFoundError` with download instructions when
a corpus path cannot be resolved (#1306)
- Migrate build backend to `hatchling` (#1311)

### Deprecated

Expand Down
8 changes: 0 additions & 8 deletions MANIFEST.in

This file was deleted.

20 changes: 11 additions & 9 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
# SPDX-License-Identifier: Apache-2.0

[build-system]
requires = ["setuptools>=69.0.0", "wheel"]
build-backend = "setuptools.build_meta"
requires = ["hatchling"]
build-backend = "hatchling.build"

[project]
name = "pythainlp"
Expand Down Expand Up @@ -297,14 +297,16 @@ issues = "https://github.com/PyThaiNLP/pythainlp/issues"
[project.scripts]
thainlp = "pythainlp.__main__:main"

[tool.setuptools]
include-package-data = true
[tool.hatch.build.targets.wheel]
packages = ["pythainlp"]

[tool.setuptools.packages.find]
exclude = ["tests", "tests.*"]

[tool.setuptools.package-data]
pythainlp = ["corpus/*"]
[tool.hatch.build.targets.sdist]
include = [
"pythainlp/",
"tests/",
"LICENSE",
"README.md",
]

# Bumpversion configuration
[tool.bumpversion]
Expand Down
Loading