Skip to content

Commit

Permalink
support python3.12
Browse files Browse the repository at this point in the history
  • Loading branch information
bymoye committed Oct 28, 2023
1 parent fec425e commit 726d9b3
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 10 deletions.
14 changes: 8 additions & 6 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: [3.8, 3.9, "3.10", "3.11"]
python-version: [3.8, 3.9, "3.10", "3.11", "3.12"]
runs-on: windows-latest
if: github.event_name == 'pull_request' || github.event_name == 'push'

Expand All @@ -40,7 +40,8 @@ jobs:

- name: Install dependencies
run: |
pip install cython==0.29.34 --config-setting no_cython_compile=True --no-cache-dir
pip install cython==3.0.4 --config-setting no_cython_compile=True --no-cache-dir
pip install setuptools
- name: Compile Cython extensions
run: |
Expand All @@ -52,7 +53,7 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest]
python-version: [3.8, 3.9, "3.10", "3.11"]
python-version: [3.8, 3.9, "3.10", "3.11", "3.12"]
runs-on: ${{ matrix.os }}

steps:
Expand All @@ -68,7 +69,8 @@ jobs:

- name: Install dependencies
run: |
pip install cython==0.29.34 --config-setting no_cython_compile=True --no-cache-dir
pip install cython==3.0.4 --config-setting no_cython_compile=True --no-cache-dir
pip install setuptools
- name: Compile Cython extensions
run: |
Expand All @@ -80,7 +82,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: [3.8, 3.9, "3.10", "3.11"]
python-version: [3.8, 3.9, "3.10", "3.11", "3.12"]
os: [ubuntu-latest, macos-latest, windows-latest]

steps:
Expand All @@ -95,7 +97,7 @@ jobs:

- name: Install build dependencies
run: |
pip install cython==0.29.34 --config-setting no_cython_compile=True --no-cache-dir
pip install cython==3.0.4 --config-setting no_cython_compile=True --no-cache-dir
python -m pip install --upgrade setuptools pip wheel build
- name: Compile Cython extensions
Expand Down
4 changes: 3 additions & 1 deletion nazo_rand/nazo_rand.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
#include <cstdint>
#include <limits>
#include <random>

#include <iostream>
#include <fstream>
#include <vector>
namespace Storm
{
using Integer = int64_t;
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ build-backend = "setuptools.build_meta"

[metadata]
name = "nazo_rand"
version = "0.0.9"
version = "0.1.0"
author = "bymoye"
author_email = "[email protected]"
readme = "README.md"
Expand Down
3 changes: 2 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
Cython==0.29.34;
setuptools
Cython==3.0.4
3 changes: 2 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def readme():
),
author="bymoye",
author_email="[email protected]",
version="0.0.9",
version="0.1.0",
description="A fast random number generator for python",
long_description=readme(),
long_description_content_type="text/markdown",
Expand All @@ -60,6 +60,7 @@ def readme():
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Cython",
"Programming Language :: C++",
"Operating System :: POSIX :: Linux",
Expand Down

0 comments on commit 726d9b3

Please sign in to comment.