Skip to content

Commit a863505

Browse files
authored
dev: review the structure of the repository to fix packaging issues (#244)
1 parent 5f3a16b commit a863505

35 files changed

+73
-68
lines changed

.github/workflows/tests.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,11 +74,15 @@ jobs:
7474
with:
7575
python-version: ${{ matrix.python.runs-on }}
7676
cache: pip
77-
cache-dependency-path: dev-requirements.txt
77+
cache-dependency-path: |
78+
dev-requirements.txt
79+
tests-requirements.txt
80+
check-latest: true
7881
- name: Install test dependencies
7982
run: |
8083
python -m pip install -U pip wheel
8184
python -m pip install -r dev-requirements.txt
85+
python -m pip install -r tests-requirements.txt
8286
- name: Install Xvfb
8387
if: matrix.os.emoji == '🐧'
8488
run: sudo apt install xvfb

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ See Git checking messages for full history.
44

55
## 8.0.3 (2023/xx/xx)
66
- added support for Python 3.12
7+
- dev: review the structure of the repository to fix packaging issues (#243)
78
- MSS: added PEP 561 compatible
89
- MSS: include more files in the sdist package (#240)
910
- MSS: remove `venv` files from the sdist package

MANIFEST.in

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ include LICENSE.txt
55
include README.md
66
include dev-requirements.txt
77
include tests-requirements.txt
8-
include mss/tests/*.py
9-
include mss/py.typed
8+
include src/tests/*.py
9+
include src/mss/py.typed
1010
recursive-include docs/source *
11-
recursive-include mss/tests/res *
11+
recursive-include src/tests/res *

check.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
#
33
# Small script to ensure quality checks pass before submitting a commit/PR.
44
#
5-
python -m isort docs mss
6-
python -m black --line-length=120 docs mss
7-
python -m flake8 docs mss
8-
python -m pylint mss
5+
python -m isort docs src
6+
python -m black --line-length=120 docs src
7+
python -m flake8 docs src
8+
python -m pylint src/mss
99
# "--platform win32" to not fail on ctypes.windll (it does not affect the overall check on other OSes)
10-
python -m mypy --platform win32 --exclude mss/tests mss docs/source/examples
10+
python -m mypy --platform win32 --exclude src/tests src docs/source/examples

setup.cfg

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -43,15 +43,16 @@ classifiers =
4343
Topic :: Software Development :: Libraries
4444

4545
[options]
46-
zip_safe = False
47-
include_package_data = True
48-
packages = find_namespace:
4946
python_requires = >=3.8
47+
package_dir =
48+
= src
49+
packages = find:
5050

5151
[options.packages.find]
52-
include =
53-
mss
54-
mss.*
52+
where = src
53+
54+
[options.package_data]
55+
mss = py.typed
5556

5657
[options.entry_points]
5758
console_scripts =
@@ -85,6 +86,7 @@ output-format = colorized
8586
reports = no
8687

8788
[tool:pytest]
89+
pythonpath = src
8890
addopts =
8991
--showlocals
9092
--strict-markers
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)