Skip to content

Commit

Permalink
Start testing for Python 3.12 (#83)
Browse files Browse the repository at this point in the history
* Start testing for Python 3.12

* Fix issue found by CodeQL - Inefficient regular expression
  • Loading branch information
martin-majlis authored Feb 21, 2024
1 parent b367254 commit 337e03b
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/tox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python: ["3.8", "3.9", "3.10", "3.11"]
python: ["3.8", "3.9", "3.10", "3.11", "3.12"]

steps:
- uses: actions/checkout@v2
Expand Down
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Wikipedia API
Installation
------------

This package requires at least Python 3.4 to install because it's using IntEnum.
This package requires at least Python 3.8 to install because it's using IntEnum.

.. code-block:: python
Expand Down
9 changes: 4 additions & 5 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@ def fix_doc(txt):
"""
Fixes documentation so that it's readable in pypi website.
"""
return re.sub(r"\.\. PYPI-BEGIN([\r\n]|.)*?PYPI-END", "", txt, re.DOTALL)
return re.sub(
r"\.\. PYPI-BEGIN([\r\n]|[^\r\n])*?PYPI-END", "", txt, flags=re.DOTALL
)


with open("README.rst", encoding="utf8") as fileR:
Expand All @@ -34,14 +36,11 @@ def fix_doc(txt):
"Intended Audience :: Developers",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"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",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
"License :: OSI Approved :: MIT License",
Expand Down

0 comments on commit 337e03b

Please sign in to comment.