diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e4283446..7a605fd7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -9,18 +9,20 @@ jobs: os: - ubuntu-20.04 dc: + - dmd-2.108.1 - dmd-2.101.2 + - ldc-1.38.0 - ldc-1.30.0 python-version: + - '3.12' + - '3.11' - '3.10' - - '3.9' - - '3.8' runs-on: ${{ matrix.os }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Install package dependencies run: | @@ -29,12 +31,12 @@ jobs: - name: Install D compiler # must go before setting LD_LIBRARY_PATH for Python since this overrides it - uses: dlang-community/setup-dlang@v1.3.0 + uses: dlang-community/setup-dlang@v1.4.0 with: compiler: ${{ matrix.dc }} - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} @@ -66,4 +68,4 @@ jobs: LD_RUN_PATH: $PYTHON_LIB_DIR LIBRARY_PATH: /usr/lib/llvm-10/lib - - uses: codecov/codecov-action@v3 + - uses: codecov/codecov-action@v4 diff --git a/Makefile b/Makefile index 50706b74..c9636971 100644 --- a/Makefile +++ b/Makefile @@ -4,7 +4,7 @@ DC ?= dmd export PYTHON_LIB_DIR ?= /usr/lib export DUB_CONFIGURATION ?= env export PYD_LIBPYTHON_DIR ?= /usr/lib -export PYD_LIBPYTHON ?= python3.9 +export PYD_LIBPYTHON ?= $(shell python --version | awk '{print $$2}' | awk -F. '{print "python" $$1 "." $$2}') export PYD_D_VERSION_1 ?= Python_2_4_Or_Later export PYD_D_VERSION_2 ?= Python_2_5_Or_Later export PYD_D_VERSION_3 ?= Python_2_6_Or_Later diff --git a/dub.selections.json b/dub.selections.json index 486d05ab..bebf27f6 100644 --- a/dub.selections.json +++ b/dub.selections.json @@ -1,8 +1,8 @@ { "fileVersion": 1, "versions": { - "mirror": "0.3.2", - "monty": "0.0.12", - "unit-threaded": "2.0.3" + "mirror": "0.3.3", + "monty": "0.0.14", + "unit-threaded": "2.2.0" } } diff --git a/examples/issues/dub.selections.json b/examples/issues/dub.selections.json index c998c426..f59d7f9e 100644 --- a/examples/issues/dub.selections.json +++ b/examples/issues/dub.selections.json @@ -8,7 +8,7 @@ "memutils": "1.0.10", "mir-linux-kernel": "1.0.1", "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "openssl": "3.3.3", "openssl-static": "1.0.3+3.0.8", "pyd": "0.14.4", diff --git a/examples/numpy/dub.selections.json b/examples/numpy/dub.selections.json index 532825f9..67621982 100644 --- a/examples/numpy/dub.selections.json +++ b/examples/numpy/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../"}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_algorithm/dub.selections.json b/examples/phobos/std_algorithm/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_algorithm/dub.selections.json +++ b/examples/phobos/std_algorithm/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_array/dub.selections.json b/examples/phobos/std_array/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_array/dub.selections.json +++ b/examples/phobos/std_array/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_ascii/dub.selections.json b/examples/phobos/std_ascii/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_ascii/dub.selections.json +++ b/examples/phobos/std_ascii/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_base64/dub.selections.json b/examples/phobos/std_base64/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_base64/dub.selections.json +++ b/examples/phobos/std_base64/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_bigint/dub.selections.json b/examples/phobos/std_bigint/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_bigint/dub.selections.json +++ b/examples/phobos/std_bigint/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_compiler/dub.selections.json b/examples/phobos/std_compiler/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_compiler/dub.selections.json +++ b/examples/phobos/std_compiler/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_complex/dub.selections.json b/examples/phobos/std_complex/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_complex/dub.selections.json +++ b/examples/phobos/std_complex/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_container/dub.selections.json b/examples/phobos/std_container/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_container/dub.selections.json +++ b/examples/phobos/std_container/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_conv/dub.selections.json b/examples/phobos/std_conv/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_conv/dub.selections.json +++ b/examples/phobos/std_conv/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_csv/dub.selections.json b/examples/phobos/std_csv/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_csv/dub.selections.json +++ b/examples/phobos/std_csv/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_demangle/dub.selections.json b/examples/phobos/std_demangle/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_demangle/dub.selections.json +++ b/examples/phobos/std_demangle/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_encoding/dub.selections.json b/examples/phobos/std_encoding/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_encoding/dub.selections.json +++ b/examples/phobos/std_encoding/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_exception/dub.selections.json b/examples/phobos/std_exception/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_exception/dub.selections.json +++ b/examples/phobos/std_exception/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_format/dub.selections.json b/examples/phobos/std_format/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_format/dub.selections.json +++ b/examples/phobos/std_format/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_functional/dub.selections.json b/examples/phobos/std_functional/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_functional/dub.selections.json +++ b/examples/phobos/std_functional/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_getopt/dub.selections.json b/examples/phobos/std_getopt/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_getopt/dub.selections.json +++ b/examples/phobos/std_getopt/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_json/dub.selections.json b/examples/phobos/std_json/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_json/dub.selections.json +++ b/examples/phobos/std_json/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_math/dub.selections.json b/examples/phobos/std_math/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_math/dub.selections.json +++ b/examples/phobos/std_math/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_mathspecial/dub.selections.json b/examples/phobos/std_mathspecial/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_mathspecial/dub.selections.json +++ b/examples/phobos/std_mathspecial/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_meta/dub.selections.json b/examples/phobos/std_meta/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_meta/dub.selections.json +++ b/examples/phobos/std_meta/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_mmfile/dub.selections.json b/examples/phobos/std_mmfile/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_mmfile/dub.selections.json +++ b/examples/phobos/std_mmfile/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_numeric/dub.selections.json b/examples/phobos/std_numeric/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_numeric/dub.selections.json +++ b/examples/phobos/std_numeric/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_outbuffer/dub.selections.json b/examples/phobos/std_outbuffer/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_outbuffer/dub.selections.json +++ b/examples/phobos/std_outbuffer/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_path/dub.selections.json b/examples/phobos/std_path/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_path/dub.selections.json +++ b/examples/phobos/std_path/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_process/dub.selections.json b/examples/phobos/std_process/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_process/dub.selections.json +++ b/examples/phobos/std_process/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_random/dub.selections.json b/examples/phobos/std_random/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_random/dub.selections.json +++ b/examples/phobos/std_random/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_range/dub.selections.json b/examples/phobos/std_range/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_range/dub.selections.json +++ b/examples/phobos/std_range/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_regex/dub.selections.json b/examples/phobos/std_regex/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_regex/dub.selections.json +++ b/examples/phobos/std_regex/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_signals/dub.selections.json b/examples/phobos/std_signals/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_signals/dub.selections.json +++ b/examples/phobos/std_signals/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_socket/dub.selections.json b/examples/phobos/std_socket/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_socket/dub.selections.json +++ b/examples/phobos/std_socket/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_stdint/dub.selections.json b/examples/phobos/std_stdint/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_stdint/dub.selections.json +++ b/examples/phobos/std_stdint/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_stdio/dub.selections.json b/examples/phobos/std_stdio/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_stdio/dub.selections.json +++ b/examples/phobos/std_stdio/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_string/dub.selections.json b/examples/phobos/std_string/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_string/dub.selections.json +++ b/examples/phobos/std_string/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_system/dub.selections.json b/examples/phobos/std_system/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_system/dub.selections.json +++ b/examples/phobos/std_system/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_traits/dub.selections.json b/examples/phobos/std_traits/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_traits/dub.selections.json +++ b/examples/phobos/std_traits/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_typecons/dub.selections.json b/examples/phobos/std_typecons/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_typecons/dub.selections.json +++ b/examples/phobos/std_typecons/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_typetuple/dub.selections.json b/examples/phobos/std_typetuple/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_typetuple/dub.selections.json +++ b/examples/phobos/std_typetuple/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_uri/dub.selections.json b/examples/phobos/std_uri/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_uri/dub.selections.json +++ b/examples/phobos/std_uri/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_utf/dub.selections.json b/examples/phobos/std_utf/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_utf/dub.selections.json +++ b/examples/phobos/std_utf/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_uuid/dub.selections.json b/examples/phobos/std_uuid/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_uuid/dub.selections.json +++ b/examples/phobos/std_uuid/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_variant/dub.selections.json b/examples/phobos/std_variant/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_variant/dub.selections.json +++ b/examples/phobos/std_variant/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_windows/dub.selections.json b/examples/phobos/std_windows/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_windows/dub.selections.json +++ b/examples/phobos/std_windows/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/phobos/std_zlib/dub.selections.json b/examples/phobos/std_zlib/dub.selections.json index 6d0f0d88..79e8afed 100644 --- a/examples/phobos/std_zlib/dub.selections.json +++ b/examples/phobos/std_zlib/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../.."}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/pyd/dub.selections.json b/examples/pyd/dub.selections.json index 532825f9..67621982 100644 --- a/examples/pyd/dub.selections.json +++ b/examples/pyd/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../../"}, "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "pyd": "0.14.4", "unit-threaded": "2.1.9" } diff --git a/examples/simple/adder/dub.selections.json b/examples/simple/adder/dub.selections.json index 89f0c36f..fd2ef9d9 100644 --- a/examples/simple/adder/dub.selections.json +++ b/examples/simple/adder/dub.selections.json @@ -6,7 +6,7 @@ "excel-d": "0.5.12", "localimport": "1.3.0", "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "nogc": "0.5.1", "pyd": "0.14.4", "scriptlike": "0.10.3", diff --git a/examples/simple/api/dub.selections.json b/examples/simple/api/dub.selections.json index 89f0c36f..fd2ef9d9 100644 --- a/examples/simple/api/dub.selections.json +++ b/examples/simple/api/dub.selections.json @@ -6,7 +6,7 @@ "excel-d": "0.5.12", "localimport": "1.3.0", "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "nogc": "0.5.1", "pyd": "0.14.4", "scriptlike": "0.10.3", diff --git a/examples/simple/dub.selections.json b/examples/simple/dub.selections.json index 98abfa8a..b1bcf335 100644 --- a/examples/simple/dub.selections.json +++ b/examples/simple/dub.selections.json @@ -6,7 +6,7 @@ "excel-d": "0.5.12", "localimport": "1.3.0", "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "nogc": "0.5.1", "pyd": "0.14.4", "scriptlike": "0.10.3", diff --git a/examples/simple/prefix/dub.selections.json b/examples/simple/prefix/dub.selections.json index 89f0c36f..fd2ef9d9 100644 --- a/examples/simple/prefix/dub.selections.json +++ b/examples/simple/prefix/dub.selections.json @@ -6,7 +6,7 @@ "excel-d": "0.5.12", "localimport": "1.3.0", "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "nogc": "0.5.1", "pyd": "0.14.4", "scriptlike": "0.10.3", diff --git a/examples/simple/structs/dub.selections.json b/examples/simple/structs/dub.selections.json index 89f0c36f..fd2ef9d9 100644 --- a/examples/simple/structs/dub.selections.json +++ b/examples/simple/structs/dub.selections.json @@ -6,7 +6,7 @@ "excel-d": "0.5.12", "localimport": "1.3.0", "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "nogc": "0.5.1", "pyd": "0.14.4", "scriptlike": "0.10.3", diff --git a/examples/simple/templates/dub.selections.json b/examples/simple/templates/dub.selections.json index 89f0c36f..fd2ef9d9 100644 --- a/examples/simple/templates/dub.selections.json +++ b/examples/simple/templates/dub.selections.json @@ -6,7 +6,7 @@ "excel-d": "0.5.12", "localimport": "1.3.0", "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "nogc": "0.5.1", "pyd": "0.14.4", "scriptlike": "0.10.3", diff --git a/examples/simple/wrap_all/dub.selections.json b/examples/simple/wrap_all/dub.selections.json index 89f0c36f..fd2ef9d9 100644 --- a/examples/simple/wrap_all/dub.selections.json +++ b/examples/simple/wrap_all/dub.selections.json @@ -6,7 +6,7 @@ "excel-d": "0.5.12", "localimport": "1.3.0", "mirror": "0.3.3", - "monty": "0.0.12", + "monty": "0.0.14", "nogc": "0.5.1", "pyd": "0.14.4", "scriptlike": "0.10.3", diff --git a/pynih/contract/dub.selections.json b/pynih/contract/dub.selections.json index 58d4cf98..b18541bc 100644 --- a/pynih/contract/dub.selections.json +++ b/pynih/contract/dub.selections.json @@ -3,7 +3,7 @@ "versions": { "autowrap": {"path":"../.."}, "mirror": "0.3.2", - "monty": "0.0.1", + "monty": "0.0.14", "unit-threaded": "1.0.4" } } diff --git a/pynih/contract/source/contract/pyclass.d b/pynih/contract/source/contract/pyclass.d index 6303f874..c4146e13 100644 --- a/pynih/contract/source/contract/pyclass.d +++ b/pynih/contract/source/contract/pyclass.d @@ -79,7 +79,7 @@ package PyObject* pyclass_string_list_struct(PyObject* self, PyObject *args) { return null; } - const length = PyUnicode_GetSize(item); + const length = PyUnicode_GetLength(item); auto ptr = PyBytes_AsString(unicode); auto str = ptr is null ? null : ptr[0 .. length]; diff --git a/pynih/contract/source/contract/scalars.d b/pynih/contract/source/contract/scalars.d index 8fbe343f..2c18d1da 100644 --- a/pynih/contract/source/contract/scalars.d +++ b/pynih/contract/source/contract/scalars.d @@ -37,7 +37,7 @@ package PyObject* one_bool_param_to_not(PyObject* self, PyObject *args) nothrow if(arg is null) return null; if(!PyBool_Check(arg)) return null; - const dArg = arg == pyTrue; + const dArg = arg == Py_True; return PyBool_FromLong(!dArg); } diff --git a/pynih/contract/source/contract/udt.d b/pynih/contract/source/contract/udt.d index a3d1f625..28b60dcf 100644 --- a/pynih/contract/source/contract/udt.d +++ b/pynih/contract/source/contract/udt.d @@ -34,7 +34,7 @@ package PyObject* simple_struct_func(PyObject* self, PyObject *args) nothrow @no type.tp_name = &"MyType"[0]; type.tp_basicsize = MyType.sizeof; type.tp_members = &members[0]; - type.tp_flags = TypeFlags.Default; + type.tp_flags = Py_TPFLAGS_DEFAULT; if(PyType_Ready(&type) < 0) { PyErr_SetString(PyExc_TypeError, &"not ready"[0]); @@ -87,7 +87,7 @@ package PyObject* twice_struct_func(PyObject* self, PyObject *args) nothrow @nog type.tp_name = &"Twice"[0]; type.tp_basicsize = Twice.sizeof; type.tp_methods = &methods[0]; - type.tp_flags = TypeFlags.Default; + type.tp_flags = Py_TPFLAGS_DEFAULT; if(PyType_Ready(&type) < 0) { PyErr_SetString(PyExc_TypeError, &"not ready"[0]); @@ -224,7 +224,7 @@ package PyObject* struct_getset(PyObject* self, PyObject *args) nothrow @nogc { outerType.tp_name = &"StructGetSet"[0]; outerType.tp_basicsize = StructGetSet.sizeof; - outerType.tp_flags = TypeFlags.Default; + outerType.tp_flags = Py_TPFLAGS_DEFAULT; outerType.tp_repr = outerType.tp_str = &reprOuter; outerType.tp_getset = &outerGetSets[0]; @@ -242,7 +242,7 @@ package PyObject* struct_getset(PyObject* self, PyObject *args) nothrow @nogc { innerType.tp_name = &"StructGetSet.Inner"[0]; innerType.tp_basicsize = StructGetSet.Inner.sizeof; - innerType.tp_flags = TypeFlags.Default; + innerType.tp_flags = Py_TPFLAGS_DEFAULT; innerType.tp_repr = innerType.tp_str = &reprInner; innerType.tp_getset = &innerGetSets[0]; diff --git a/pynih/source/autowrap/pynih/python/conv/python_to_d.d b/pynih/source/autowrap/pynih/python/conv/python_to_d.d index c2bc48a6..27dddbaa 100644 --- a/pynih/source/autowrap/pynih/python/conv/python_to_d.d +++ b/pynih/source/autowrap/pynih/python/conv/python_to_d.d @@ -233,11 +233,11 @@ T to(T)(PyObject* value) if(isArray!T && !isSomeString!T) T to(T)(PyObject* value) if(isSomeString!T) { - import python.c: PyUnicode_GetSize, PyUnicode_Check, + import python.c: PyUnicode_GetLength, PyUnicode_Check, PyBytes_AsString, PyUnicode_AsUTF8String, Py_ssize_t; import std.conv: to; - const length = PyUnicode_GetSize(value); + const length = PyUnicode_GetLength(value); if(length == 0) return T.init; auto str = PyUnicode_AsUTF8String(value); @@ -253,8 +253,8 @@ T to(T)(PyObject* value) if(isSomeString!T) { T to(T)(PyObject* value) if(is(Unqual!T == bool)) { - import python.c: pyTrue; - return value is pyTrue; + import python.c: Py_True; + return value is Py_True; } diff --git a/pynih/source/autowrap/pynih/python/cooked.d b/pynih/source/autowrap/pynih/python/cooked.d index 21a876e1..83ee86b4 100644 --- a/pynih/source/autowrap/pynih/python/cooked.d +++ b/pynih/source/autowrap/pynih/python/cooked.d @@ -20,7 +20,7 @@ auto createModule(Module module_, alias cfunctions, alias aggregates = Aggregate static PyModuleDef moduleDef; auto pyMethodDefs = cFunctionsToPyMethodDefs!(cfunctions); - moduleDef = pyModuleDef(module_.name.ptr, null /*doc*/, -1 /*size*/, pyMethodDefs); + moduleDef = PyModuleDef(pyModuleDefHeadInit, module_.name.ptr, null /*doc*/, -1 /*size*/, pyMethodDefs); auto module_ = PyModule_Create(&moduleDef); addModuleTypes!(aggregates.Types)(module_); @@ -73,20 +73,6 @@ private PyMethodDef* cFunctionsToPyMethodDefs(alias cfunctions)() } -/** - Helper function to get around the C syntax problem with - PyModuleDef_HEAD_INIT - it doesn't compile in D. -*/ -private auto pyModuleDef(A...)(auto ref A args) { - import std.functional: forward; - - return PyModuleDef( - // the line below is a manual D version expansion of PyModuleDef_HEAD_INIT - PyModuleDef_Base(PyObject(1 /*ref count*/, null /*type*/), null /*m_init*/, 0/*m_index*/, null/*m_copy*/), - forward!args - ); -} - /** Helper function to create PyMethodDef structs. The strings are compile-time parameters to avoid passing GC-allocated memory diff --git a/pynih/source/autowrap/pynih/python/type.d b/pynih/source/autowrap/pynih/python/type.d index c053b741..48e12cea 100644 --- a/pynih/source/autowrap/pynih/python/type.d +++ b/pynih/source/autowrap/pynih/python/type.d @@ -63,7 +63,7 @@ struct PythonType(T) { private static void initialise() nothrow { import autowrap.common: AlwaysTry; - import python.c: PyType_GenericNew, PyType_Ready, TypeFlags, + import python.c: PyType_GenericNew, PyType_Ready, Py_TPFLAGS_DEFAULT, Py_TPFLAGS_BASETYPE, PyErr_SetString, PyExc_TypeError, PyNumberMethods, PySequenceMethods; import mirror.meta.traits: UnaryOperators, BinaryOperators, AssignOperators, functionName; @@ -76,9 +76,9 @@ struct PythonType(T) { // This allows tp_name to do its usual Python job and allows us to // construct a D class from its runtime Python type. _pyType.tp_name = fullyQualifiedName!(Unqual!T).ptr; - _pyType.tp_flags = TypeFlags.Default; + _pyType.tp_flags = Py_TPFLAGS_DEFAULT; static if(is(T == class) || is(T == interface)) - _pyType.tp_flags |= TypeFlags.BaseType; + _pyType.tp_flags |= Py_TPFLAGS_BASETYPE; // FIXME: types are that user aggregates *and* callables static if(isUserAggregate!T) { diff --git a/requirements.txt b/requirements.txt index f5e037ac..f982921e 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,22 +1,7 @@ -attrs==21.2.0 -blessings==1.7 -bpython==0.21 -certifi==2023.7.22 -chardet==4.0.0 -curtsies==0.3.5 -cwcwidth==0.1.4 -greenlet==1.1.0 -idna==3.7 -iniconfig==1.1.1 -numpy==1.22.0 -packaging==20.9 -pluggy==0.13.1 -py==1.10.0 -Pygments==2.15.0 -pyparsing==2.4.7 -pytest==6.2.4 -pyxdg==0.27 -requests==2.32.0 -six==1.16.0 -toml==0.10.2 -urllib3==1.26.18 +exceptiongroup==1.2.1 +iniconfig==2.0.0 +numpy==1.26.4 +packaging==24.0 +pluggy==1.5.0 +pytest==8.2.1 +tomli==2.0.1