Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/buildwheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ jobs:
- name: Build and test wheels
env:
# skip 32-bit, musllinux, and free-threaded builds
CIBW_SKIP: "*-win32 *-manylinux_i686 *musllinux* cp3??t-*"
CIBW_SKIP: "*-win32 *-manylinux_i686 *musllinux* cp3??t-* cp314-macosx_x86_64 cp315-macosx_x86_64"
CIBW_BEFORE_BUILD_WINDOWS: pip install delvewheel
CIBW_ENVIRONMENT_WINDOWS: CMAKE_ARGS="-DCMAKE_MAKE_PROGRAM=D:/a/_temp/msys64/mingw64/bin/ninja.exe" CMAKE_PROGRAM_PATH="D:/a/_temp/msys64/usr/bin" CMAKE_GENERATOR="Ninja" TEMP="D:/a/_temp/"
CIBW_REPAIR_WHEEL_COMMAND_WINDOWS: delvewheel repair -w {dest_dir} {wheel}
Expand Down
10 changes: 8 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -588,10 +588,16 @@ endif()

### pedantics ######################################################################################

# temporarily disable -Werror specifically for Linux + Python 3.15 TODO #555
set(PYPARTMC_WERROR "-Werror")
if(CMAKE_SYSTEM_NAME STREQUAL "Linux" AND Python_VERSION VERSION_EQUAL "3.15")
set(PYPARTMC_WERROR "")
endif()

foreach(target _PyPartMC)
target_compile_options(${target} PRIVATE
$<$<CXX_COMPILER_ID:MSVC>:/W4 /WX>
$<$<NOT:$<CXX_COMPILER_ID:MSVC>>:-Wall -Wextra -Wpedantic -Werror -Wno-unused-parameter>
$<$<NOT:$<CXX_COMPILER_ID:MSVC>>:-Wall -Wextra -Wpedantic ${PYPARTMC_WERROR} -Wno-unused-parameter>
)
endforeach()

Expand All @@ -613,7 +619,7 @@ if (NOT "${CMAKE_REQUIRED_INCLUDES}" STREQUAL "")
endif()
foreach(file ${PyPartMC_headers})
set(CMAKE_REQUIRED_INCLUDES "${PYPARTMC_INCLUDE_DIRS};${Python_INCLUDE_DIRS}")
set(CMAKE_REQUIRED_FLAGS "-Werror")
set(CMAKE_REQUIRED_FLAGS "${PYPARTMC_WERROR}")
string(REGEX REPLACE "[\-./:]" "_" file_var ${file})
check_cxx_source_compiles("
// https://github.com/nlohmann/json/issues/1408
Expand Down
4 changes: 2 additions & 2 deletions examples/additive_coag_comparison.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@
"source": [
"from collections import namedtuple\n",
"from functools import partial\n",
"import urllib\n",
"from urllib import request\n",
"import json\n",
"import platform\n",
"import subprocess\n",
Expand Down Expand Up @@ -518,7 +518,7 @@
" 'src/SDfunc/constants.jl', 'src/SDfunc/binning.jl', 'src/SDfunc/coalescence.jl',\n",
" ):\n",
" with open('Droplets.jl-' + path.replace('/','-'), 'w', encoding='utf-8') as fout:\n",
" with urllib.request.urlopen(BASE_URL + path) as fin:\n",
" with request.urlopen(BASE_URL + path) as fin:\n",
" fout.write(fin.read().decode('utf-8'))\n",
"\n",
" code_to_write = \"\"\"\n",
Expand Down
4 changes: 2 additions & 2 deletions examples/particle_simulation_with_camp.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"outputs": [],
"source": [
"import json\n",
"import urllib\n",
"from urllib import request\n",
"from collections import defaultdict\n",
"import numpy as np\n",
"import matplotlib.pyplot as plt\n",
Expand Down Expand Up @@ -119,7 +119,7 @@
"for path in PATHS:\n",
" print(path)\n",
" with open(path, 'w', encoding='utf-8') as fout:\n",
" with urllib.request.urlopen(CAMP_URL + path.replace('-', '/')) as fin:\n",
" with request.urlopen(CAMP_URL + path.replace('-', '/')) as fin:\n",
" json.dump(\n",
" json.loads(fin.read().decode('utf-8').replace('TO' + 'DO', 'TO-DO')),\n",
" fout,\n",
Expand Down
Loading