From f4d75ed221a7603f7c740597b5a043cc15bcf801 Mon Sep 17 00:00:00 2001 From: Matthew Black Date: Mon, 26 May 2025 19:50:58 -0700 Subject: [PATCH 1/5] fix: default libwally-core dependency to atomic --- external/CMakeLists.txt | 2 +- local_resource/external_project_local_setting.config | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt index 12bbcd91..780fc0ac 100644 --- a/external/CMakeLists.txt +++ b/external/CMakeLists.txt @@ -61,7 +61,7 @@ if(LIBWALLY_TARGET_URL) set(LIBWALLY_TARGET_REP ${LIBWALLY_TARGET_URL}) message(STATUS "[external project local] libwally-core url=${LIBWALLY_TARGET_URL}") else() -set(LIBWALLY_TARGET_REP cryptogarageinc/libwally-core.git) +set(LIBWALLY_TARGET_REP atomicfinance/libwally-core.git) endif() if(${USE_GIT_SSH}) diff --git a/local_resource/external_project_local_setting.config b/local_resource/external_project_local_setting.config index c50e145e..664b266f 100644 --- a/local_resource/external_project_local_setting.config +++ b/local_resource/external_project_local_setting.config @@ -1,3 +1,3 @@ CFDCORE_VERSION=0.3.19 LIBWALLY_TARGET_VERSION=refs/tags/cfd-0.3.8 -LIBWALLY_TARGET_URL=cryptogarageinc/libwally-core.git +LIBWALLY_TARGET_URL=atomicfinance/libwally-core.git From 5ac42d670071609ccef3003507c979b1bd2b8de2 Mon Sep 17 00:00:00 2001 From: Matthew Black Date: Mon, 26 May 2025 19:59:38 -0700 Subject: [PATCH 2/5] ci: modernize workflows --- .github/workflows/check_pre-merge_develop.yml | 31 +++++++------ .github/workflows/check_pre-merge_master.yml | 31 +++++++------ .github/workflows/check_pre-merge_sprint.yml | 43 +++++++++---------- .github/workflows/code_scanner.yml | 16 +++---- 4 files changed, 59 insertions(+), 62 deletions(-) diff --git a/.github/workflows/check_pre-merge_develop.yml b/.github/workflows/check_pre-merge_develop.yml index b4355b17..be0b87fc 100644 --- a/.github/workflows/check_pre-merge_develop.yml +++ b/.github/workflows/check_pre-merge_develop.yml @@ -9,22 +9,22 @@ on: - develop env: - CMAKE_VERSION: 3.17.2 + CMAKE_VERSION: 3.25.0 jobs: cmake-win-test: name: cmake build-win - runs-on: windows-2019 + runs-on: windows-2022 strategy: matrix: - generator: ['Visual Studio 16 2019', 'MSYS Makefiles'] + generator: ['Visual Studio 17 2022', 'MSYS Makefiles'] shared: [on, off] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: cmake_version run: cmake --version - - name: cmake_generage + - name: cmake_generate run: cmake -S . -B build -G "${{ matrix.generator }}" -DENABLE_SHARED=${{ matrix.shared }} - name: cmake_build run: cmake --build build --config Release --parallel 4 @@ -35,17 +35,16 @@ jobs: cmake-mac-test: name: cmake build-mac - runs-on: ${{ matrix.os }} + runs-on: self-hosted strategy: matrix: - os: [macos-10.15] -# os: [macos-10.15, macos-11.0] + runner: [macos] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: cmake_version run: cmake --version - - name: cmake_generage-macos + - name: cmake_generate-macos run: cmake -S . -B build -G "Unix Makefiles" -DENABLE_SHARED=on -DENABLE_ELEMENTS=on - name: cmake_build run: cmake --build build --config Release --parallel 4 @@ -61,15 +60,15 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-20.04, ubuntu-18.04] + os: [ubuntu-22.04, ubuntu-20.04] shared: [on, off] elements: [on, off] exclude: - - os: ubuntu-18.04 + - os: ubuntu-20.04 elements: off steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: dump version run: | cmake --version @@ -88,12 +87,12 @@ jobs: doxygen-ubuntu: name: doxygen-check - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: install_doxygen - run: sudo apt install doxygen graphviz + run: sudo apt-get update && sudo apt-get install -y doxygen graphviz - name: doxygen_check run: | cd doc diff --git a/.github/workflows/check_pre-merge_master.yml b/.github/workflows/check_pre-merge_master.yml index 53fb3588..e92e07b2 100644 --- a/.github/workflows/check_pre-merge_master.yml +++ b/.github/workflows/check_pre-merge_master.yml @@ -11,22 +11,22 @@ on: - stable_v* env: - CMAKE_VERSION: 3.17.2 + CMAKE_VERSION: 3.25.0 jobs: cmake-win-test: name: cmake build-win - runs-on: windows-2019 + runs-on: windows-2022 strategy: matrix: - generator: ['Visual Studio 16 2019', 'MSYS Makefiles'] + generator: ['Visual Studio 17 2022', 'MSYS Makefiles'] shared: [on, off] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: cmake_version run: cmake --version - - name: cmake_generage + - name: cmake_generate run: cmake -S . -B build -G "${{ matrix.generator }}" -DENABLE_SHARED=${{ matrix.shared }} - name: cmake_build run: cmake --build build --config Release --parallel 4 @@ -37,17 +37,16 @@ jobs: cmake-mac-test: name: cmake build-mac - runs-on: ${{ matrix.os }} + runs-on: self-hosted strategy: matrix: - os: [macos-10.15] -# os: [macos-10.15, macos-11.0] + runner: [macos] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: cmake_version run: cmake --version - - name: cmake_generage-macos + - name: cmake_generate-macos run: cmake -S . -B build -G "Unix Makefiles" -DENABLE_SHARED=on -DENABLE_ELEMENTS=on - name: cmake_build run: cmake --build build --config Release --parallel 4 @@ -63,15 +62,15 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-20.04, ubuntu-18.04] + os: [ubuntu-22.04, ubuntu-20.04] shared: [on, off] elements: [on, off] exclude: - - os: ubuntu-18.04 + - os: ubuntu-20.04 elements: off steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: dump version run: | cmake --version @@ -90,12 +89,12 @@ jobs: doxygen-ubuntu: name: doxygen-check - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: install_doxygen - run: sudo apt install doxygen graphviz + run: sudo apt-get update && sudo apt-get install -y doxygen graphviz - name: doxygen_check run: | cd doc diff --git a/.github/workflows/check_pre-merge_sprint.yml b/.github/workflows/check_pre-merge_sprint.yml index 8046983b..0ad955ff 100644 --- a/.github/workflows/check_pre-merge_sprint.yml +++ b/.github/workflows/check_pre-merge_sprint.yml @@ -9,22 +9,22 @@ on: - features/sprint* env: - CMAKE_VERSION: 3.15.5 + CMAKE_VERSION: 3.25.0 jobs: cmake-win: name: cmake build-win - runs-on: windows-2019 + runs-on: windows-2022 strategy: matrix: - generator: ['Visual Studio 16 2019', 'MSYS Makefiles'] + generator: ['Visual Studio 17 2022', 'MSYS Makefiles'] shared: [on] steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v4 - name: cmake_version run: cmake --version - - name: cmake_generage + - name: cmake_generate run: cmake -S . -B build -G "${{ matrix.generator }}" -DENABLE_SHARED=${{ matrix.shared }} -DENABLE_TESTS=on - name: cmake_build run: cmake --build build --config Release --parallel 4 @@ -35,17 +35,16 @@ jobs: cmake-mac: name: cmake build-mac - runs-on: ${{ matrix.os }} + runs-on: self-hosted strategy: matrix: - os: [macos-10.15] - # os: [macos-10.15, macos-11.0] + runner: [macos] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: cmake_version run: cmake --version - - name: cmake_generage-macos + - name: cmake_generate-macos run: cmake -S . -B build -G "Unix Makefiles" -DENABLE_SHARED=on - name: cmake_build run: cmake --build build --config Release --parallel 4 @@ -59,12 +58,12 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-20.04, ubuntu-18.04] + os: [ubuntu-22.04, ubuntu-20.04] shared: [on] elements: [on, off] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: dump version run: | cmake --version @@ -73,7 +72,7 @@ jobs: if: matrix.elements == 'on' run: | cat /etc/os-release - sudo apt install lcov + sudo apt-get update && sudo apt-get install -y lcov - name: cmake-build run: | cmake --version @@ -95,20 +94,20 @@ jobs: cd .. - name: upload coverage if: matrix.elements == 'on' - uses: actions/upload-artifact@v1 + uses: actions/upload-artifact@v4 with: name: output-lcov-cfdcore-${{ matrix.os }} path: ./build/lcov_cfdcore_output.zip cmake-cpp-support-test: name: cmake build-ubuntu C++ support test - runs-on: ubuntu-20.04 + runs-on: ubuntu-22.04 strategy: matrix: cppversion: [11, 14, 17, 20] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: dump version run: | cmake --version @@ -129,11 +128,11 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-18.04] + os: [ubuntu-20.04] shared: [on] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: dump version run: | cmake --version @@ -153,19 +152,19 @@ jobs: # --valgrind-stacksize=1048576 --num-callers=12 valgrind -v --tool=memcheck --leak-check=full --valgrind-stacksize=10485760 --log-file=./valgrind.log --time-stamp=yes ./build/Debug/cfdcore_test - name: upload coverage - uses: actions/upload-artifact@v1 + uses: actions/upload-artifact@v4 with: name: valgrind-log path: ./valgrind.log doxygen-ubuntu: name: doxygen-check - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: install_doxygen - run: sudo apt install doxygen graphviz + run: sudo apt-get update && sudo apt-get install -y doxygen graphviz - name: doxygen_check run: | cd doc diff --git a/.github/workflows/code_scanner.yml b/.github/workflows/code_scanner.yml index bbf68ef6..5e53146c 100644 --- a/.github/workflows/code_scanner.yml +++ b/.github/workflows/code_scanner.yml @@ -18,7 +18,7 @@ on: jobs: analyze-CodeQL: name: CodeQL - runs-on: ubuntu-18.04 + runs-on: ubuntu-22.04 strategy: fail-fast: false @@ -31,14 +31,14 @@ jobs: steps: - name: Checkout repository - uses: actions/checkout@v2 + uses: actions/checkout@v4 with: # We must fetch at least the immediate parents so that if this is a pull request then we can checkout the head. fetch-depth: 2 # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL - uses: github/codeql-action/init@v1 + uses: github/codeql-action/init@v3 with: languages: ${{ matrix.language }} # If you wish to specify custom queries, you can do so here or in a config file. @@ -49,7 +49,7 @@ jobs: # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). # If this step fails, then you should remove it and run the build manually (see below) - name: Autobuild - uses: github/codeql-action/autobuild@v1 + uses: github/codeql-action/autobuild@v3 # ℹ️ Command-line programs to run using the OS shell. # https://git.io/JvXDl @@ -61,17 +61,17 @@ jobs: # make release - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v1 + uses: github/codeql-action/analyze@v3 OSSAR-Scan: # OSSAR runs on windows-latest. # ubuntu-latest and macos-latest support coming soon - runs-on: windows-2019 + runs-on: windows-2022 steps: # Checkout your code repository to scan - name: Checkout repository - uses: actions/checkout@v2 + uses: actions/checkout@v4 with: # We must fetch at least the immediate parents so that if this is # a pull request then we can checkout the head. @@ -94,6 +94,6 @@ jobs: # Upload results to the Security tab - name: Upload OSSAR results - uses: github/codeql-action/upload-sarif@v1 + uses: github/codeql-action/upload-sarif@v3 with: sarif_file: ${{ steps.ossar.outputs.sarifFile }} From 3b3248b2d60ddb6eb8817efa2cb0fc3685810f9c Mon Sep 17 00:00:00 2001 From: Matthew Black Date: Mon, 26 May 2025 20:04:26 -0700 Subject: [PATCH 3/5] ci: disable specific gcc warnings for googletest --- external/CMakeLists.txt | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt index 780fc0ac..f93129c8 100644 --- a/external/CMakeLists.txt +++ b/external/CMakeLists.txt @@ -156,6 +156,23 @@ set(INSTALL_GTEST OFF CACHE BOOL "" FORCE) add_subdirectory(${CMAKE_SOURCE_DIR}/external/${TEMPLATE_PROJECT_NAME} ${CFD_ROOT_BINARY_DIR}/${TEMPLATE_PROJECT_NAME}/build) + +# Disable specific warnings for GoogleTest that cause issues with newer GCC versions +if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU") + if(TARGET gtest) + target_compile_options(gtest PRIVATE -Wno-maybe-uninitialized) + endif() + if(TARGET gtest_main) + target_compile_options(gtest_main PRIVATE -Wno-maybe-uninitialized) + endif() + if(TARGET gmock) + target_compile_options(gmock PRIVATE -Wno-maybe-uninitialized) + endif() + if(TARGET gmock_main) + target_compile_options(gmock_main PRIVATE -Wno-maybe-uninitialized) + endif() +endif() + set_property(GLOBAL PROPERTY ${TEMPLATE_PROJECT_NAME} 1) endif() endif() # MSVC OR ENABLE_TESTS From e1f67b36d2cbd11ad3657446bd83963d8c41daf0 Mon Sep 17 00:00:00 2001 From: Matthew Black Date: Mon, 26 May 2025 20:08:26 -0700 Subject: [PATCH 4/5] ci: limit concurrency to prevent job cancellation --- .github/workflows/check_pre-merge_develop.yml | 11 +++++++++++ .github/workflows/check_pre-merge_master.yml | 11 +++++++++++ .github/workflows/check_pre-merge_sprint.yml | 8 ++++++++ 3 files changed, 30 insertions(+) diff --git a/.github/workflows/check_pre-merge_develop.yml b/.github/workflows/check_pre-merge_develop.yml index be0b87fc..4eaec7f3 100644 --- a/.github/workflows/check_pre-merge_develop.yml +++ b/.github/workflows/check_pre-merge_develop.yml @@ -8,6 +8,11 @@ on: branches: - develop +# Limit concurrency to prevent job cancellations +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + env: CMAKE_VERSION: 3.25.0 @@ -58,7 +63,10 @@ jobs: cmake-ubuntu-test: name: cmake build runs-on: ${{ matrix.os }} + timeout-minutes: 30 strategy: + # Reduce concurrent jobs to prevent cancellations + max-parallel: 3 matrix: os: [ubuntu-22.04, ubuntu-20.04] shared: [on, off] @@ -66,6 +74,9 @@ jobs: exclude: - os: ubuntu-20.04 elements: off + # Reduce matrix size - focus on most important combinations + - os: ubuntu-20.04 + shared: off steps: - uses: actions/checkout@v4 diff --git a/.github/workflows/check_pre-merge_master.yml b/.github/workflows/check_pre-merge_master.yml index e92e07b2..22e6acb5 100644 --- a/.github/workflows/check_pre-merge_master.yml +++ b/.github/workflows/check_pre-merge_master.yml @@ -10,6 +10,11 @@ on: - master - stable_v* +# Limit concurrency to prevent job cancellations +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + env: CMAKE_VERSION: 3.25.0 @@ -60,7 +65,10 @@ jobs: cmake-ubuntu-test: name: cmake build runs-on: ${{ matrix.os }} + timeout-minutes: 30 strategy: + # Reduce concurrent jobs to prevent cancellations + max-parallel: 3 matrix: os: [ubuntu-22.04, ubuntu-20.04] shared: [on, off] @@ -68,6 +76,9 @@ jobs: exclude: - os: ubuntu-20.04 elements: off + # Reduce matrix size - focus on most important combinations + - os: ubuntu-20.04 + shared: off steps: - uses: actions/checkout@v4 diff --git a/.github/workflows/check_pre-merge_sprint.yml b/.github/workflows/check_pre-merge_sprint.yml index 0ad955ff..297a681c 100644 --- a/.github/workflows/check_pre-merge_sprint.yml +++ b/.github/workflows/check_pre-merge_sprint.yml @@ -8,6 +8,11 @@ on: branches: - features/sprint* +# Limit concurrency to prevent job cancellations +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + env: CMAKE_VERSION: 3.25.0 @@ -56,7 +61,10 @@ jobs: cmake-ubuntu-coverage: name: cmake build-ubuntu runs-on: ${{ matrix.os }} + timeout-minutes: 45 strategy: + # Reduce concurrent jobs to prevent cancellations + max-parallel: 2 matrix: os: [ubuntu-22.04, ubuntu-20.04] shared: [on] From 1ed8240b4be0b4fdbc91543d908c44ab2ee2d535 Mon Sep 17 00:00:00 2001 From: Matthew Black Date: Mon, 26 May 2025 20:13:37 -0700 Subject: [PATCH 5/5] ci: remove ubuntu 20.04 --- .github/workflows/check_pre-merge_develop.yml | 8 +------- .github/workflows/check_pre-merge_master.yml | 8 +------- .github/workflows/check_pre-merge_sprint.yml | 4 ++-- 3 files changed, 4 insertions(+), 16 deletions(-) diff --git a/.github/workflows/check_pre-merge_develop.yml b/.github/workflows/check_pre-merge_develop.yml index 4eaec7f3..ae731e30 100644 --- a/.github/workflows/check_pre-merge_develop.yml +++ b/.github/workflows/check_pre-merge_develop.yml @@ -68,15 +68,9 @@ jobs: # Reduce concurrent jobs to prevent cancellations max-parallel: 3 matrix: - os: [ubuntu-22.04, ubuntu-20.04] + os: [ubuntu-22.04] shared: [on, off] elements: [on, off] - exclude: - - os: ubuntu-20.04 - elements: off - # Reduce matrix size - focus on most important combinations - - os: ubuntu-20.04 - shared: off steps: - uses: actions/checkout@v4 diff --git a/.github/workflows/check_pre-merge_master.yml b/.github/workflows/check_pre-merge_master.yml index 22e6acb5..40c247d6 100644 --- a/.github/workflows/check_pre-merge_master.yml +++ b/.github/workflows/check_pre-merge_master.yml @@ -70,15 +70,9 @@ jobs: # Reduce concurrent jobs to prevent cancellations max-parallel: 3 matrix: - os: [ubuntu-22.04, ubuntu-20.04] + os: [ubuntu-22.04] shared: [on, off] elements: [on, off] - exclude: - - os: ubuntu-20.04 - elements: off - # Reduce matrix size - focus on most important combinations - - os: ubuntu-20.04 - shared: off steps: - uses: actions/checkout@v4 diff --git a/.github/workflows/check_pre-merge_sprint.yml b/.github/workflows/check_pre-merge_sprint.yml index 297a681c..5d7ea57c 100644 --- a/.github/workflows/check_pre-merge_sprint.yml +++ b/.github/workflows/check_pre-merge_sprint.yml @@ -66,7 +66,7 @@ jobs: # Reduce concurrent jobs to prevent cancellations max-parallel: 2 matrix: - os: [ubuntu-22.04, ubuntu-20.04] + os: [ubuntu-22.04] shared: [on] elements: [on, off] @@ -136,7 +136,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-20.04] + os: [ubuntu-22.04] shared: [on] steps: