diff --git a/.audit/oberstet_fix_1985.md b/.audit/oberstet_fix_1985.md new file mode 100644 index 000000000..9f91eb37a --- /dev/null +++ b/.audit/oberstet_fix_1985.md @@ -0,0 +1,8 @@ +- [ ] I did **not** use any AI-assistance tools to help create this pull request. +- [x] I **did** use AI-assistance tools to *help* create this pull request. +- [x] I have read, understood and followed the project's AI_POLICY.md when creating code, documentation etc. for this pull request. + +Submitted by: @oberstet +Date: 2026-10-18 +Related issue(s): #1985 +Branch: oberstet:fix_1985 diff --git a/docs/changelog.rst b/docs/changelog.rst index 9e24fdd3a..7da395cf2 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -22,6 +22,7 @@ Changelog * Adopt the contribution workflow shared by all WAMP projects: ``CONTRIBUTING.md``, the pull request template and ``.audit/README.md`` are now deployed byte-identically from wamp-cicd (GitHub issue first, red → green tests, AI-assistance disclosure) and kept in sync by a CI drift check; everything specific to Autobahn|Python moved to a new ``DEVELOPMENT.md`` (also included in the docs). ``.cicd`` is pinned to wamp-cicd ``38ded6a``, the same commit across the WAMP fleet (#1956) * Remove the opt-in entropy depletion tests (``autobahn/test/test_rng.py``, enabled by ``AUTOBAHN_CI_ENABLE_RNG_DEPLETION_TESTS``, never run in CI): they read ``/proc/sys/kernel/random/entropy_avail``, which has been a constant 256 since Linux 5.18, and ``/dev/random`` no longer blocks since Linux 5.6, so one test passed whatever happened and the other always failed (#1278) * Build the ARM64 Linux wheels natively on GitHub's ``ubuntu-24.04-arm`` runners instead of under QEMU emulation on x86_64 runners, as zlmdb does since #183. Under emulation the builds took around 40 minutes (up to 96) and segfaulted intermittently, so each build had 9 attempts of 120 minutes; the same container images and build script are used, and a build attempt now gets 60 minutes and 3 tries (#1940) +* Build the bundled ``flatc`` on all cores: ``hatch_build.py`` ran ``cmake --build`` without ``--parallel``, so ``flatc`` was compiled on one core in every wheel build, editable install and ``just test-*`` run. It now passes ``--parallel ``; an explicit ``CMAKE_BUILD_PARALLEL_LEVEL`` in the environment still wins. Measured on a 32-core host: 237 s serial, 25 s with 16 jobs. Skipping the build when ``flatc``'s inputs did not change is still open (#1985) * Add an ``import-smoke-lowest`` CI job (``just test-imports-lowest``) that runs the import smoke test on CPython 3.11 with every direct dependency resolved to the lowest version ``pyproject.toml`` allows (``uv --resolution lowest-direct``), so stale version floors are caught. The import smoke test now also covers the Twisted and asyncio bindings, each module imported in a fresh interpreter (#1955) **asyncio** diff --git a/hatch_build.py b/hatch_build.py index 3a2776a18..90dc801da 100644 --- a/hatch_build.py +++ b/hatch_build.py @@ -247,8 +247,9 @@ def _build_flatc(self, build_data): print(f"ERROR: cmake configure failed:\n{result.stderr}") return False - # Step 2: Build flatc - print(" -> Building flatc...") + # Step 2: Build flatc, on all cores (#1985). An explicit + # CMAKE_BUILD_PARALLEL_LEVEL in the environment wins: cmake reads it + # itself when --parallel is given without a job count. build_args = [ cmake_path, "--build", @@ -257,7 +258,15 @@ def _build_flatc(self, build_data): "Release", "--target", "flatc", + "--parallel", ] + jobs = os.environ.get("CMAKE_BUILD_PARALLEL_LEVEL") + if jobs: + print(f" -> Building flatc ({jobs} jobs, CMAKE_BUILD_PARALLEL_LEVEL)...") + else: + jobs = str(os.cpu_count() or 1) + build_args.append(jobs) + print(f" -> Building flatc ({jobs} parallel jobs)...") result = subprocess.run( build_args,