diff --git a/.github/workflows/full-build.yml b/.github/workflows/full-build.yml index 4c3733fcbb..2e46933911 100644 --- a/.github/workflows/full-build.yml +++ b/.github/workflows/full-build.yml @@ -93,8 +93,8 @@ jobs: *.rpm *OpenStudio*x86_64.tar.gz cpack_generators: "RPM;TGZ" - max_jobs: 2 - exclude_regex: "^BCLFixture.RemoteBCLMetaSearchTest$" + max_jobs: 4 + exclude_regex: "^(BCLFixture.RemoteBCLMetaSearchTest|BCLFixture.BCLMeasure)$" - platform: ubuntu-2204-x64 pretty: Ubuntu 22.04 x64 os: ubuntu-22.04 @@ -107,8 +107,8 @@ jobs: *.deb *OpenStudio*x86_64.tar.gz cpack_generators: "DEB;TGZ" - max_jobs: 2 - exclude_regex: "^ModelFixture.PythonPluginInstance_NotPYFile$" + max_jobs: 3 + exclude_regex: "^(ModelFixture.PythonPluginInstance_NotPYFile|BCLFixture.BCLMeasure)$" - platform: ubuntu-2404-x64 pretty: Ubuntu 24.04 x64 os: ubuntu-24.04 @@ -121,8 +121,8 @@ jobs: *.deb *OpenStudio*x86_64.tar.gz cpack_generators: "DEB;TGZ" - max_jobs: 2 - exclude_regex: ${{ '""' }} + max_jobs: 4 + exclude_regex: "^BCLFixture.BCLMeasure$" - platform: ubuntu-2204-arm64 pretty: Ubuntu 22.04 ARM64 os: ubuntu-22.04-arm @@ -135,8 +135,8 @@ jobs: *.deb *OpenStudio*arm64.tar.gz cpack_generators: "DEB;TGZ" - max_jobs: 2 - exclude_regex: "^(GeometryFixture.Plane_RayIntersection|ISOModelFixture.SimModel|SqlFileFixture.AnnualTotalCosts|OpenStudioCLI.*test_measure_manager)$" + max_jobs: 3 + exclude_regex: "^(GeometryFixture.Plane_RayIntersection|ISOModelFixture.SimModel|SqlFileFixture.AnnualTotalCosts|OpenStudioCLI.*test_measure_manager|BCLFixture.BCLMeasure)$" - platform: ubuntu-2404-arm64 pretty: Ubuntu 24.04 ARM64 os: ubuntu-24.04-arm @@ -149,8 +149,8 @@ jobs: *.deb *OpenStudio*arm64.tar.gz cpack_generators: "DEB;TGZ" - max_jobs: 2 - exclude_regex: "^(GeometryFixture.Plane_RayIntersection|ISOModelFixture.SimModel|SqlFileFixture.AnnualTotalCosts|OpenStudioCLI.*test_measure_manager)$" + max_jobs: 4 + exclude_regex: "^(GeometryFixture.Plane_RayIntersection|ISOModelFixture.SimModel|SqlFileFixture.AnnualTotalCosts|OpenStudioCLI.*test_measure_manager|BCLFixture.BCLMeasure)$" defaults: run: shell: bash @@ -163,8 +163,16 @@ jobs: contents: write steps: - - name: Verify space + - name: Enable Swap and Verify space run: | + echo "Enabling Swap..." + # Create and enable 8GB swap file to prevent OOM kills + dd if=/dev/zero of=/mnt/swapfile_extra bs=1M count=8192 status=progress + chmod 600 /mnt/swapfile_extra + mkswap /mnt/swapfile_extra + swapon /mnt/swapfile_extra + + echo echo "Memory and swap:" # Check if free exists before running it, or ignore failure if command -v free >/dev/null 2>&1; then @@ -283,7 +291,11 @@ jobs: - name: Install CA Certificates if: startsWith(matrix.platform, 'ubuntu') - run: apt-get update && apt-get install -y ca-certificates + run: | + apt-get update || true + apt-get install -y ca-certificates gnupg wget + wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | gpg --dearmor - | tee /etc/apt/trusted.gpg.d/kitware.gpg >/dev/null + apt-get update - name: Conan install run: | @@ -328,6 +340,7 @@ jobs: -DPYTHON_VERSION:STRING=${{ env.PYTHON_REQUIRED_VERSION }} \ -DSYSTEM_RUBY_EXECUTABLE="$SYSTEM_RUBY_PATH" \ -DCMAKE_INSTALL_RPATH='$ORIGIN;$ORIGIN/../lib' \ + -DCMAKE_JOB_POOL_LINK:STRING=console \ "$GITHUB_WORKSPACE" - name: Build with Ninja @@ -452,7 +465,7 @@ jobs: run: | set -euo pipefail . ./conanbuild.sh - cmake --build . --target package + cpack -C ${{ env.BUILD_TYPE }} - name: Cleanup intermediate files if: always() @@ -538,7 +551,7 @@ jobs: if: inputs.skip_docker_trigger != 'true' && github.event.inputs.skip_docker_trigger != 'true' working-directory: installers env: - GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GH_TOKEN: ${{ secrets.DOCKER_OPENSTUDIO_PAT }} BRANCH_NAME: ${{ github.ref_name }} S3_PREFIX: ${{ github.ref_type == 'tag' && format('releases/{0}', github.ref_name) || format('{0}', github.ref_name) }} run: | @@ -612,13 +625,14 @@ jobs: name: Build Packages for ${{ matrix.pretty }} if: "!inputs.jobs || contains(inputs.jobs, 'macos-build')" runs-on: ${{ matrix.os }} + timeout-minutes: 720 continue-on-error: ${{ matrix.allow_failure }} strategy: fail-fast: false matrix: - macos_dev_target: [12.1, 13.0] + macos_dev_target: ["12.1", "13.0"] include: - - macos_dev_target: 12.1 + - macos_dev_target: "12.1" platform: macos-x64 pretty: "macOS x64" os: macos-15-intel @@ -628,9 +642,9 @@ jobs: python-arch: x64 dmg_glob: "*.dmg" tar_glob: "*OpenStudio*x86_64.tar.gz" - exclude_regex: ${{ '""' }} - max_jobs: 2 - - macos_dev_target: 13.0 + exclude_regex: "^BCLFixture.BCLMeasure$" + max_jobs: 3 + - macos_dev_target: "13.0" platform: macos-arm64 pretty: "macOS ARM64" os: macos-15 @@ -640,8 +654,8 @@ jobs: python-arch: arm64 dmg_glob: "*.dmg" tar_glob: "*OpenStudio*arm64.tar.gz" - exclude_regex: "^(GeometryFixture.Plane_RayIntersection|ISOModelFixture.SimModel)$" - max_jobs: 2 + exclude_regex: "^(GeometryFixture.Plane_RayIntersection|ISOModelFixture.SimModel|BCLFixture.BCLMeasure)$" + max_jobs: 3 env: MAX_BUILD_THREADS: ${{ matrix.max_jobs }} CTEST_PARALLEL_LEVEL: ${{ matrix.max_jobs }} @@ -657,6 +671,20 @@ jobs: path: ${{ env.OPENSTUDIO_SOURCE }} fetch-depth: 1 + - name: Verify space + shell: bash + run: | + echo "Memory and swap:" + if command -v vm_stat >/dev/null 2>&1; then + vm_stat + fi + echo + sysctl vm.swapusage || true + echo + echo "Available storage:" + df -h . || true + echo + - name: Git safe directory working-directory: ${{ env.OPENSTUDIO_SOURCE }} run: git config --global --add safe.directory '*' @@ -769,6 +797,7 @@ jobs: --output-folder=../${{ env.OPENSTUDIO_BUILD }} \ --build=missing \ -c tools.cmake.cmaketoolchain:generator=Ninja \ + -c tools.build:cxxflags='["-Wno-enum-constexpr-conversion", "-D_LIBCPP_ENABLE_CXX17_REMOVED_UNARY_BINARY_FUNCTION"]' \ -s compiler.cppstd=20 \ -s build_type=${{ env.BUILD_TYPE }} \ -s os.version=${{ matrix.macos_dev_target }} \ @@ -818,6 +847,7 @@ jobs: "${CCACHE_ARGS[@]}" \ "${SIGNING_ARGS[@]}" \ -DCMAKE_TOOLCHAIN_FILE=conan_toolchain.cmake \ + -DCMAKE_CXX_FLAGS="-D_LIBCPP_ENABLE_CXX17_REMOVED_UNARY_BINARY_FUNCTION -Wno-enum-constexpr-conversion" \ -DENABLE_COVERAGE:BOOL=OFF \ -DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=${{ matrix.macos_dev_target }} \ -DCMAKE_BUILD_TYPE:STRING=${{ env.BUILD_TYPE }} \ @@ -829,6 +859,7 @@ jobs: -DCMAKE_INSTALL_RPATH="@loader_path;@executable_path;@loader_path/../lib" \ -DPYTHON_VERSION:STRING=${{ env.PYTHON_REQUIRED_VERSION }} \ -DPython_ROOT_DIR:PATH="$(dirname $(dirname $SYSTEM_PYTHON_PATH))" \ + -DCMAKE_JOB_POOL_LINK:STRING=console \ ../${{ env.OPENSTUDIO_SOURCE }} - name: Build with Ninja @@ -939,7 +970,7 @@ jobs: run: | set -euo pipefail . ./conanbuild.sh - ninja -j ${{ matrix.max_jobs }} package + cpack -C ${{ env.BUILD_TYPE }} - name: Cleanup intermediate files if: always() @@ -1158,6 +1189,7 @@ jobs: name: Build ${{ matrix.pretty }} if: "!inputs.jobs || contains(inputs.jobs, 'windows-build')" runs-on: ${{ matrix.os }} + timeout-minutes: 720 strategy: fail-fast: false matrix: @@ -1170,8 +1202,8 @@ jobs: arch: x86_64 python-arch: x64 allow_failure: false - max_jobs: 3 - exclude_regex: "^(RubyTest-Date_Test-ymd_constructor)$" + max_jobs: 4 + exclude_regex: "^(RubyTest-Date_Test-ymd_constructor|BCLFixture.BCLMeasure)$" defaults: run: shell: pwsh @@ -1190,6 +1222,11 @@ jobs: path: ${{ env.OPENSTUDIO_SOURCE }} fetch-depth: 1 + - name: Verify space + run: | + Get-PSDrive C | Select-Object Used,Free + Get-CimInstance Win32_OperatingSystem | Select-Object TotalVisibleMemorySize,FreePhysicalMemory,TotalVirtualMemorySize,FreeVirtualMemory + - name: Git safe directory working-directory: ${{ env.OPENSTUDIO_SOURCE }} run: git config --global --add safe.directory '*' @@ -1350,7 +1387,7 @@ jobs: working-directory: ${{ env.OPENSTUDIO_BUILD }} run: | $sccacheExe = (Get-Command sccache).Source - & $env:ComSpec /c "call conanbuild.bat && cmake -G Ninja -DCMAKE_C_COMPILER_LAUNCHER=`"$sccacheExe`" -DCMAKE_CXX_COMPILER_LAUNCHER=`"$sccacheExe`" -DCMAKE_TOOLCHAIN_FILE=conan_toolchain.cmake -DCMAKE_BUILD_TYPE:STRING=${{ env.BUILD_TYPE }} -DBUILD_TESTING:BOOL=ON -DCPACK_GENERATOR:STRING=`"NSIS;TGZ`" -DBUILD_PYTHON_BINDINGS:BOOL=ON -DBUILD_PYTHON_PIP_PACKAGE:BOOL=OFF -DPython_EXECUTABLE:FILEPATH=`"$env:SYSTEM_PYTHON_PATH`" -DPYTHON_VERSION:STRING=${{ env.PYTHON_REQUIRED_VERSION }} -DSYSTEM_RUBY_EXECUTABLE=`"%SYSTEM_RUBY_PATH%`" `"../${{ env.OPENSTUDIO_SOURCE }}"`" + & $env:ComSpec /c "call conanbuild.bat && cmake -G Ninja -DCMAKE_C_COMPILER_LAUNCHER=`"$sccacheExe`" -DCMAKE_CXX_COMPILER_LAUNCHER=`"$sccacheExe`" -DCMAKE_TOOLCHAIN_FILE=conan_toolchain.cmake -DCMAKE_BUILD_TYPE:STRING=${{ env.BUILD_TYPE }} -DBUILD_TESTING:BOOL=ON -DCPACK_GENERATOR:STRING=`"NSIS;TGZ`" -DBUILD_PYTHON_BINDINGS:BOOL=ON -DBUILD_PYTHON_PIP_PACKAGE:BOOL=OFF -DPython_EXECUTABLE:FILEPATH=`"$env:SYSTEM_PYTHON_PATH`" -DPYTHON_VERSION:STRING=${{ env.PYTHON_REQUIRED_VERSION }} -DSYSTEM_RUBY_EXECUTABLE=`"%SYSTEM_RUBY_PATH%`" -DCMAKE_JOB_POOL_LINK:STRING=console `"../${{ env.OPENSTUDIO_SOURCE }}"`" - name: Build with Ninja working-directory: ${{ env.OPENSTUDIO_BUILD }} @@ -1557,7 +1594,7 @@ jobs: if: ${{ success() && !cancelled() }} working-directory: ${{ env.OPENSTUDIO_BUILD }} run: | - & $env:ComSpec /c "call conanbuild.bat && cmake --build . --target package --parallel ${{ matrix.max_jobs }}" + & $env:ComSpec /c "call conanbuild.bat && cpack -C ${{ env.BUILD_TYPE }}" - name: Code sign installer if: success() && (github.ref == 'refs/heads/develop' || github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/v') || inputs.publish_to_s3 == 'true' || github.event.inputs.publish_to_s3 == 'true') diff --git a/.github/workflows/incremental-build.yml b/.github/workflows/incremental-build.yml index 08610701bf..5f3f434ceb 100644 --- a/.github/workflows/incremental-build.yml +++ b/.github/workflows/incremental-build.yml @@ -30,6 +30,7 @@ jobs: OPENSTUDIO_DOCKER_VOLUME: /github/home/Ubuntu OPENSTUDIO_SOURCE_NAME: OpenStudio OPENSTUDIO_BUILD_NAME: OS-build + EXCLUDED_TESTS: "BCLFixture.BCLMeasure" container: # Define the Docker container for the job. All subsequent steps run inside it. image: nrel/openstudio-cmake-tools:jammy-main @@ -172,7 +173,7 @@ jobs: # First test run - quiet by default, show failures only echo "Testing..." - ctest -j ${{ env.MAX_SAFE_THREADS }} --no-compress-output --output-junit Testing/run1/results.xml > /tmp/run1.log 2>&1 + ctest -j ${{ env.MAX_SAFE_THREADS }} --no-compress-output --output-junit Testing/run1/results.xml -E "${{ env.EXCLUDED_TESTS }}" > /tmp/run1.log 2>&1 RESULT1=$? if [ $RESULT1 -ne 0 ]; then @@ -182,7 +183,7 @@ jobs: # Retry failed tests echo "Retrying failed tests..." - ctest -j ${{ env.MAX_SAFE_THREADS }} --rerun-failed --no-compress-output --output-junit Testing/run2/results.xml > /tmp/run2.log 2>&1 + ctest -j ${{ env.MAX_SAFE_THREADS }} --rerun-failed --no-compress-output --output-junit Testing/run2/results.xml -E "${{ env.EXCLUDED_TESTS }}" > /tmp/run2.log 2>&1 RESULT2=$? if [ $RESULT2 -ne 0 ]; then @@ -191,7 +192,7 @@ jobs: # Final attempt with verbose output for failing tests echo "Final attempt with verbose output..." - ctest -j ${{ env.MAX_SAFE_THREADS }} --rerun-failed --no-compress-output --output-junit Testing/run3/results.xml 2>&1 | tee /tmp/run3.log + ctest -j ${{ env.MAX_SAFE_THREADS }} --rerun-failed --no-compress-output --output-junit Testing/run3/results.xml -E "${{ env.EXCLUDED_TESTS }}" 2>&1 | tee /tmp/run3.log RESULT3=$? else RESULT3=0 @@ -205,7 +206,7 @@ jobs: # Verify no remaining failures echo "Verifying no remaining failures..." - ctest --rerun-failed --no-tests=error > /dev/null 2>&1 + ctest --rerun-failed --no-tests=error -E "${{ env.EXCLUDED_TESTS }}" > /dev/null 2>&1 FINAL_CHECK=$? # Summary diff --git a/CMakeLists.txt b/CMakeLists.txt index 04fe74c4ee..77a60cf292 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -165,7 +165,7 @@ get_directory_property(hasParent PARENT_DIRECTORY) # TODO: Modify the more specific variables as needed to indicate prerelease, etc # Keep in beta in-between release cycles. Set to empty string (or comment out) for official) -set(PROJECT_VERSION_PRERELEASE "rc2") +set(PROJECT_VERSION_PRERELEASE "rc3") # OpenStudio version: Only include Major.Minor.Patch, eg "3.0.0", even if you have a prerelease tag set(OPENSTUDIO_VERSION "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH}") @@ -861,7 +861,7 @@ if(BUILD_CLI) set(OPENSTUDIO_GEMS_BASEURL "http://openstudio-resources.s3.amazonaws.com/dependencies") # TODO: temp - set(OPENSTUDIO_GEMS_BASEURL "https://github.com/NREL/openstudio-gems/releases/download/v3.11.0-RC3") + set(OPENSTUDIO_GEMS_BASEURL "https://github.com/NREL/openstudio-gems/releases/download/v3.11.0") # To use the package produced by a PR to https://github.com/NREL/openstudio-gems set(USE_OPENSTUDIO_GEMS_PR FALSE) @@ -873,19 +873,19 @@ if(BUILD_CLI) if(UNIX) if(APPLE) if (ARCH MATCHES arm64) - set(OPENSTUDIO_GEMS_ZIP_FILENAME "openstudio3-gems-20251217-darwin_arm64-3.2.2.tar.gz") - set(OPENSTUDIO_GEMS_ZIP_EXPECTED_MD5 "e98e776c563cf401bab9c3e7a6ff468a") + set(OPENSTUDIO_GEMS_ZIP_FILENAME "openstudio3-gems-20260106-darwin_arm64-3.2.2.tar.gz") + set(OPENSTUDIO_GEMS_ZIP_EXPECTED_MD5 "c0183e900f2ce0828d0c5d550224f823") else() - set(OPENSTUDIO_GEMS_ZIP_FILENAME "openstudio3-gems-20251217-darwin-3.2.2.tar.gz") - set(OPENSTUDIO_GEMS_ZIP_EXPECTED_MD5 "90be1ae437236cbfde23c657eebfcc81") + set(OPENSTUDIO_GEMS_ZIP_FILENAME "openstudio3-gems-20260106-darwin-3.2.2.tar.gz") + set(OPENSTUDIO_GEMS_ZIP_EXPECTED_MD5 "9f00eb1a2b3ff224ade4953cd355225d") endif() else() if (ARCH MATCHES "arm64") - set(OPENSTUDIO_GEMS_ZIP_FILENAME "openstudio3-gems-20251217-linux_arm64-3.2.2.tar.gz") - set(OPENSTUDIO_GEMS_ZIP_EXPECTED_MD5 "266d1eb8fbca44af569b9ebdf426978f") + set(OPENSTUDIO_GEMS_ZIP_FILENAME "openstudio3-gems-20260106-linux_arm64-3.2.2.tar.gz") + set(OPENSTUDIO_GEMS_ZIP_EXPECTED_MD5 "abbc644c67afc476bdee5a14c2d43900") else() - set(OPENSTUDIO_GEMS_ZIP_FILENAME "openstudio3-gems-20251217-linux-3.2.2.tar.gz") - set(OPENSTUDIO_GEMS_ZIP_EXPECTED_MD5 "16815be4cf8571bd17a240ae31505cd1") + set(OPENSTUDIO_GEMS_ZIP_FILENAME "openstudio3-gems-20260106-linux-3.2.2.tar.gz") + set(OPENSTUDIO_GEMS_ZIP_EXPECTED_MD5 "983d9545f151193487b8446676c06df2") endif() if (USE_OPENSTUDIO_GEMS_PR) set(OPENSTUDIO_GEMS_BASEURL "${OPENSTUDIO_GEMS_BASEURL}/openstudio-gems-linux/${OPENSTUDIO_GEMS_PR_NUMBER}") @@ -893,8 +893,8 @@ if(BUILD_CLI) endif() elseif(WIN32) # OpenStudio gems are only supported on 64 bit windows - set(OPENSTUDIO_GEMS_ZIP_FILENAME "openstudio3-gems-20251217-windows-3.2.2.tar.gz") - set(OPENSTUDIO_GEMS_ZIP_EXPECTED_MD5 "42b43e4e38d93745751d6f3be7405adb") + set(OPENSTUDIO_GEMS_ZIP_FILENAME "openstudio3-gems-20260106-windows-3.2.2.tar.gz") + set(OPENSTUDIO_GEMS_ZIP_EXPECTED_MD5 "35b4af50f7507e0d59cb05a4b6c65540") if (USE_OPENSTUDIO_GEMS_PR) set(OPENSTUDIO_GEMS_BASEURL "${OPENSTUDIO_GEMS_BASEURL}/openstudio-gems-windows/${OPENSTUDIO_GEMS_PR_NUMBER}") endif()