Skip to content

Commit

Permalink
Add support and testing for Python 3.12
Browse files Browse the repository at this point in the history
  • Loading branch information
ragibson committed Oct 5, 2023
1 parent 608c1e2 commit c0697cc
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11"]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]

steps:
- uses: actions/checkout@v3
Expand All @@ -28,6 +28,7 @@ jobs:
python -m pip install --upgrade pip
python -m venv env
source env/bin/activate
pip install setuptools
pip install cython flake8 pytest
python setup.py install
- name: Lint with flake8
Expand Down
3 changes: 2 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
author="Ryan Gibson",
author_email="[email protected]",
name="stego-lsb",
version="1.5.3",
version="1.5.4",
description="Least Significant Bit Steganography for bitmap images (.bmp "
"and .png), WAV sound files, and byte sequences. Simple LSB "
"Steganalysis (LSB extraction) for bitmap images.",
Expand Down Expand Up @@ -43,6 +43,7 @@
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3 :: Only",
],
)
2 changes: 1 addition & 1 deletion tests/test_wavsteg.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def write_random_wav(self, filename: str, num_channels: int, sample_width: int,

data = np.random.randint(0, 2 ** (8 * sample_width), dtype=dtype, size=num_frames * num_channels)
# note: typing does not recognize that "writeframes() accepts any bytes-like object" (see documentation)
file.writeframes(data) # type: ignore
file.writeframes(data) # type: ignore[arg-type,unused-ignore]

def write_random_file(self, filename: str, num_bytes: int) -> None:
with open(filename, "wb") as file:
Expand Down

0 comments on commit c0697cc

Please sign in to comment.