diff --git a/.github/workflows/build_nix.yml b/.github/workflows/build_nix.yml index 6126cd330..4c0720832 100644 --- a/.github/workflows/build_nix.yml +++ b/.github/workflows/build_nix.yml @@ -21,7 +21,7 @@ jobs: fail-fast: false max-parallel: 4 matrix: - python-version: ['3.7', '3.9', '3.10'] # '3.8' has "'tp_print' is deprecated [-Werror,-Wdeprecated-declarations]" + python-version: ['3.7', '3.9', '3.10', '3.11'] # '3.8' has "'tp_print' is deprecated [-Werror,-Wdeprecated-declarations]" steps: - uses: actions/checkout@v2 diff --git a/.github/workflows/build_win.yml b/.github/workflows/build_win.yml index b874d553e..02f9e873d 100644 --- a/.github/workflows/build_win.yml +++ b/.github/workflows/build_win.yml @@ -11,6 +11,7 @@ env: TICK_DEBUG: 0 TICK_WERROR: 0 MKN_CL_PREFERRED: 1 + MKN_COMPILE_THREADS: 2 jobs: build: @@ -21,10 +22,10 @@ jobs: fail-fast: false max-parallel: 4 matrix: - python-version: ['3.7'] # '3.8', '3.9', '3.10', have dll init issues + python-version: ['3.7', '3.8', '3.9', '3.10', '3.11'] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 with: submodules: true diff --git a/lib/mkn.yaml b/lib/mkn.yaml index b2946533d..b94115212 100644 --- a/lib/mkn.yaml +++ b/lib/mkn.yaml @@ -21,7 +21,7 @@ property: lib_path: ./../tick cargs: -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -D_FILE_OFFSET_BITS=64 -DPYTHON_LINK -DNDEBUG - win_cargs: -GL -MD -EHsc -DBUILDING_DLL -std:c++11 + win_cargs: -GL -MD -EHsc -DBUILDING_DLL nixish_cargs: -fwrapv -O2 -Wall -fstack-protector-strong -Wformat -Werror -Wdate-time @@ -53,7 +53,7 @@ profile: if_link: nix_lib: ${nix_largs} bsd_lib: ${bsd_largs} - win: -nodefaultlib:libucrt.lib ucrt.lib -MANIFEST:EMBED,ID=2 -MANIFESTUAC:NO -LTCG + win: -LTCG # -nodefaultlib:libucrt.lib ucrt.lib -MANIFEST:EMBED,ID=2 -MANIFESTUAC:NO - name: base parent: arg diff --git a/lib/swig/tick/array/array_module.i b/lib/swig/tick/array/array_module.i index 86e81f270..617e99b41 100644 --- a/lib/swig/tick/array/array_module.i +++ b/lib/swig/tick/array/array_module.i @@ -10,12 +10,14 @@ #include "numpy/arrayobject.h" #include "numpy/npy_math.h" +#ifndef _WIN32 // initialize python and numpy int tick_import_numpy(){ Py_Initialize(); return _import_array(); } static const int tick_numpy_import = tick_import_numpy(); +#endif #include "tick/base/debug.h" #include "tick/array/carray_python.h" diff --git a/sh/configure_env.sh b/sh/configure_env.sh index 29a02a206..44e8a2f2a 100755 --- a/sh/configure_env.sh +++ b/sh/configure_env.sh @@ -17,7 +17,7 @@ # ###################################################################### -set -ex +set -e echo "Entering configure_env.sh" @@ -329,7 +329,7 @@ MKN=${MKN:-mkn} export MKN_LIB_LINK_LIB=1 export TICK_CONFIGURED=1 -echo "Finished configure_env.sh for python (${PYVER}.${PYVER_MIN}) with the following args" +echo "Finished configure_env.sh for python (${PYVER}) with the following args" echo "LDARGS = ${LDARGS}" echo "" ## diff --git a/sh/mkn.sh b/sh/mkn.sh index bef11cab0..1a4dbaca5 100755 --- a/sh/mkn.sh +++ b/sh/mkn.sh @@ -25,7 +25,7 @@ pushd $CWD/.. 2>&1 > /dev/null ROOT=$PWD popd 2>&1 > /dev/null -source $ROOT/sh/configure_env.sh +source $CWD/configure_env.sh COMPILE=1 LINK=1 diff --git a/tick/base/tests/base_test.py b/tick/base/tests/base_test.py index eaaec8a30..7338259ef 100644 --- a/tick/base/tests/base_test.py +++ b/tick/base/tests/base_test.py @@ -1,6 +1,7 @@ # License: BSD 3 clause # -*- coding: utf8 -*- +import sys import unittest from tick.base import Base @@ -471,7 +472,10 @@ def test_getter_only_native_property(self): def frop(x): self.a0.readonly_prop = x - self.assertRaisesRegex(AttributeError, "can't set attribute", frop, 45) + msg = "can't set attribute" + if sys.version_info[1] == 11: + msg = "property 'readonly_prop' of 'A0' object has no setter" + self.assertRaisesRegex(AttributeError, msg, frop, 45) def test_attributes_are_not_shared(self): """...Test that two instances of the same class do not share any