Skip to content

Commit 9d13974

Browse files
committed
Set minimum Python 3.9, move project metadata to pyproject.toml
1 parent 4a7bd1d commit 9d13974

7 files changed

Lines changed: 36 additions & 75 deletions

File tree

.github/actions/test/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ runs:
8787
working-directory: ${{ inputs.pyshp_repo_directory }}
8888
run: |
8989
python -m pip install --upgrade pip
90-
pip install -r requirements.test.txt
90+
pip install -e .[test]
9191
9292
- name: Pytest
9393
shell: bash

.github/workflows/run_tests_hooks_and_tools.yml

Lines changed: 0 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -30,41 +30,6 @@ jobs:
3030
run: |
3131
pylint --disable=R,C test_shapefile.py
3232
33-
test_on_EOL_Pythons:
34-
strategy:
35-
fail-fast: false
36-
matrix:
37-
python-version: [
38-
"2.7",
39-
"3.5",
40-
"3.6",
41-
"3.7",
42-
"3.8",
43-
]
44-
45-
runs-on: ubuntu-latest
46-
container:
47-
image: python:${{ matrix.python-version }}
48-
49-
steps:
50-
- uses: actions/checkout@v4
51-
with:
52-
path: ./Pyshp
53-
54-
- name: Non-network tests
55-
uses: ./Pyshp/.github/actions/test
56-
with:
57-
pyshp_repo_directory: ./Pyshp
58-
python-version: ${{ matrix.python-version }}
59-
60-
- name: Network tests
61-
uses: ./Pyshp/.github/actions/test
62-
with:
63-
extra_args: '-m network'
64-
replace_remote_urls_with_localhost: 'yes'
65-
pyshp_repo_directory: ./Pyshp
66-
python-version: ${{ matrix.python-version }}
67-
6833
test_on_supported_Pythons:
6934
strategy:
7035
fail-fast: false

README.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,6 @@ Both the Esri and XBase file-formats are very simple in design and memory
7474
efficient which is part of the reason the shapefile format remains popular
7575
despite the numerous ways to store and exchange GIS data available today.
7676

77-
Pyshp is compatible with Python 2.7-3.x.
78-
7977
This document provides examples for using PyShp to read and write shapefiles. However
8078
many more examples are continually added to the blog [http://GeospatialPython.com](http://GeospatialPython.com),
8179
and by searching for PyShp on [https://gis.stackexchange.com](https://gis.stackexchange.com).

pyproject.toml

Lines changed: 35 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,39 @@
22
requires = ["setuptools"]
33
build-backend = "setuptools.build_meta"
44

5+
[project]
6+
name = "pyshp"
7+
authors = [
8+
{name = "Joel Lawhead", email = "jlawhead@geospatialpython.com"},
9+
]
10+
maintainers = [
11+
{name = "Karim Bahgat", email = "karim.bahgat.norway@gmail.com"}
12+
]
13+
readme = "README.md"
14+
keywords = ["gis", "geospatial", "geographic", "shapefile", "shapefiles"]
15+
description = "Pure Python read/write support for ESRI Shapefile format"
16+
license = "MIT"
17+
license-files = ["LICENSE.TXT"]
18+
dynamic = ["version"]
19+
requires-python = ">=3.9"
20+
classifiers = [
21+
"Development Status :: 5 - Production/Stable",
22+
"Programming Language :: Python",
23+
"Programming Language :: Python :: 3",
24+
"Programming Language :: Python :: 3 :: Only",
25+
"Topic :: Scientific/Engineering :: GIS",
26+
"Topic :: Software Development :: Libraries",
27+
"Topic :: Software Development :: Libraries :: Python Modules",
28+
]
29+
30+
[project.optional-dependencies]
31+
test = ["pytest"]
32+
33+
[project.urls]
34+
Repository = "https://github.com/GeospatialPython/pyshp"
35+
36+
[tool.setuptools.dynamic]
37+
version = {attr = "shapefile.__version__"}
538

639
[tool.ruff]
740
# Exclude a variety of commonly ignored directories.
@@ -39,7 +72,7 @@ line-length = 88
3972
indent-width = 4
4073

4174
# Assume Python 3.9
42-
target-version = "py37"
75+
target-version = "py39"
4376

4477
[tool.ruff.lint]
4578
# Enable Pyflakes (`F`) and a subset of the pycodestyle (`E`) codes by default.
@@ -86,4 +119,4 @@ load-plugins=[
86119
per-file-ignores = """
87120
shapefile.py:W0212
88121
test_shapefile.py:W0212
89-
"""
122+
"""

requirements.test.txt

Lines changed: 0 additions & 2 deletions
This file was deleted.

setup.cfg

Lines changed: 0 additions & 30 deletions
This file was deleted.

setup.py

Lines changed: 0 additions & 3 deletions
This file was deleted.

0 commit comments

Comments
 (0)