Skip to content

ci: Standardize common_system checkout using actions/checkout@v4 #284

Description

@kcenon

Summary

Standardize the common_system checkout method from git clone to actions/checkout@v4 in the CI workflow, and remove optional dependency logic.

Background

thread_system has integrated C++20 Concepts from common_system (#271, #279). The current CI workflow still uses git clone with continue-on-error handling, which is inconsistent with other systems (container_system, logger_system).

Current State (Problem)

- name: Checkout common_system (optional dependency - Unix)
  if: runner.os != 'Windows'
  continue-on-error: true
  run: |
    cd ..
    if [ ! -d "common_system" ]; then
      git clone https://github.com/kcenon/common_system.git || echo "not available"
    fi

Proposed Changes

- name: Checkout common_system
  uses: actions/checkout@v4
  with:
    repository: kcenon/common_system
    path: common_system
    token: ${{ secrets.GITHUB_TOKEN }}

Benefits

  1. Consistency: Same pattern as other systems (container_system, logger_system)
  2. Reliability: Leverage actions/checkout@v4 caching and error handling
  3. Simplicity: Remove OS-specific branching logic
  4. Clarity: Clearly express that this is a required dependency

Changes Required

.github/workflows/ci.yml

  1. Remove existing git clone approach (separate Unix/Windows steps)
  2. Unify with actions/checkout@v4
  3. Remove conditional BUILD_WITH_COMMON logic
  4. Fix BUILD_WITH_COMMON_SYSTEM=ON

cmake/ThreadSystemDependencies.cmake

  1. Add workspace-relative path for common_system checkout (${CMAKE_CURRENT_SOURCE_DIR}/common_system/include)

codecov.yml

  1. Adjust project coverage target from 80% to 55% (realistic baseline)
  2. Adjust patch coverage target from 80% to 60%
  3. Add gradual improvement plan comments (Phase 1: 55% → Phase 2: 65% → Phase 3: 75%)

README.md / README_KO.md

  1. Add Requirements section with common_system listed
  2. Update installation instructions to include common_system clone
  3. Update dependency flow diagram

Acceptance Criteria

  • Replace separate Unix/Windows common_system checkout steps with single actions/checkout step
  • Remove continue-on-error
  • Remove conditional build flag logic
  • All platform CI tests pass (Ubuntu, macOS, Windows)
  • Document common_system as required dependency in README.md
  • Adjust codecov coverage targets to realistic baseline (55% project, 60% patch)
  • Codecov checks pass with new targets

Related

Notes

After this change, other projects using thread_system (such as logger_system) must also checkout common_system together.

Coverage Target Adjustment Rationale

The previous 80% coverage target was unrealistic given the current test coverage (~59%). The new targets establish a realistic baseline while maintaining quality standards:

Metric Old Target New Target Current
Project 80% 55% ~59%
Patch 80% 60% -

A gradual improvement plan is documented in codecov.yml for future coverage increases.

Metadata

Metadata

Assignees

Labels

ci-cdCI/CD and build automationdependenciesExternal dependencies management

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions