Skip to content

Explicitly include Cet CMake modules - #678

Merged
knoepfel merged 2 commits into
mainfrom
bugfix/includes-with-standalone-cetmodules
Jun 30, 2026
Merged

knoepfel merged 2 commits into
mainfrom
bugfix/includes-with-standalone-cetmodules

Conversation

@greenc-FNAL

@greenc-FNAL greenc-FNAL commented Jun 30, 2026 •

Copy link
Copy Markdown
Contributor

Add explicit include() calls for CetCMakeEnv, CetCMakeConfig,
CetMakeLibrary, and CetMake across the project's CMake configuration.

This ensures that the cet_ helper functions are explicitly defined before
use, improving build system maintainability and avoiding reliance on
implicit inclusion.

  • Build system

    • Added explicit CET module imports across CMake files to ensure helper macros/functions are available before use:
      • include(CetCMakeEnv) in the top-level CMakeLists.txt
      • include(CetCMakeConfig) before cet_cmake_config()
      • include(CetMakeLibrary) in phlex/CMakeLists.txt
      • include(CetMake) in phlex/app/CMakeLists.txt
    • This reduces reliance on implicit module loading and makes the build configuration more maintainable.
  • Impact

    • No public API or exported entity changes.
    • No functional source-code changes; build configuration only.

Add explicit `include()` calls for `CetCMakeEnv`, `CetCMakeConfig`,
`CetMakeLibrary`, and `CetMake` across the project's CMake configuration.

This ensures that the `cet_` helper functions are explicitly defined before
use, improving build system maintainability and avoiding reliance on
implicit inclusion.
@greenc-FNAL
greenc-FNAL requested a review from knoepfel June 30, 2026 13:38
@coderabbitai

coderabbitai Bot commented Jun 30, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

Important

Review skipped

Auto incremental reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 7aae4009-67a0-408d-b8d1-03ae536f2f88

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Adds explicit include() directives for CET CMake helpers (CetCMakeEnv, CetCMakeConfig, CetMakeLibrary, CetMake) in the root CMakeLists.txt, phlex/CMakeLists.txt, and phlex/app/CMakeLists.txt to make these dependencies explicit rather than implicitly available.

CET CMake explicit includes

Layer / File(s) Summary
Explicit CET CMake include directives
CMakeLists.txt, phlex/CMakeLists.txt, phlex/app/CMakeLists.txt
Adds include(CetCMakeEnv) after project() and include(CetCMakeConfig) before cet_cmake_config() in the root file; adds include(CetMakeLibrary) at the top of phlex/CMakeLists.txt; adds include(CetMake) at the top of phlex/app/CMakeLists.txt.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: adding explicit includes for Cet CMake modules.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch bugfix/includes-with-standalone-cetmodules

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@greenc-FNAL

greenc-FNAL commented Jun 30, 2026 •

Copy link
Copy Markdown
Contributor Author

21 fixed, 0 new since branch point (d26f7c3)
21 fixed, 0 new since previous report on PR (a71aa8a)

✅ 21 CodeQL alerts resolved since the previous PR commit

  • ✅ Warning # 196 actions/untrusted-checkout-toctou/critical at .github/workflows/clang-tidy-fix.yaml:109:9 — Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
  • ✅ Warning # 227 actions/untrusted-checkout-toctou/high at .github/workflows/clang-format-fix.yaml:94:9 — Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
    Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
  • ✅ Warning # 228 actions/untrusted-checkout-toctou/high at .github/workflows/python-fix.yaml:94:9 — Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
    Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
  • ✅ Warning # 229 actions/untrusted-checkout/high at .github/workflows/clang-format-fix.yaml:94:9 — Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
    Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
  • ✅ Warning # 230 actions/untrusted-checkout/high at .github/workflows/python-fix.yaml:94:9 — Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
    Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
  • ✅ Warning # 231 actions/untrusted-checkout-toctou/high at .github/workflows/cmake-format-fix.yaml:94:9 — Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
    Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
  • ✅ Warning # 232 actions/untrusted-checkout-toctou/high at .github/workflows/jsonnet-format-fix.yaml:95:9 — Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
    Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
  • ✅ Warning # 233 actions/untrusted-checkout/high at .github/workflows/cmake-format-fix.yaml:94:9 — Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
    Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
  • ✅ Warning # 234 actions/untrusted-checkout/high at .github/workflows/jsonnet-format-fix.yaml:95:9 — Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
    Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
  • ✅ Warning # 235 actions/untrusted-checkout/medium at .github/workflows/clang-format-check.yaml:82:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 236 actions/untrusted-checkout/medium at .github/workflows/actionlint-check.yaml:86:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 237 actions/untrusted-checkout/medium at .github/workflows/clang-tidy-check.yaml:59:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 238 actions/untrusted-checkout/medium at .github/workflows/cmake-format-check.yaml:79:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 239 actions/untrusted-checkout/medium at .github/workflows/cmake-build.yaml:159:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 240 actions/untrusted-checkout/medium at .github/workflows/header-guards-check.yaml:82:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 241 actions/untrusted-checkout/medium at .github/workflows/jsonnet-format-check.yaml:79:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 242 actions/untrusted-checkout/medium at .github/workflows/markdown-check.yaml:82:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 243 actions/untrusted-checkout/medium at .github/workflows/python-check.yaml:84:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 244 actions/untrusted-checkout/medium at .github/workflows/yaml-check.yaml:76:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 245 actions/untrusted-checkout-toctou/high at .github/workflows/coverage.yaml:386:9 — Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
  • ✅ …and 1 more alerts (see Code Scanning for the full list).

✅ 21 CodeQL alerts resolved since the branch point

  • ✅ Warning # 196 actions/untrusted-checkout-toctou/critical at .github/workflows/clang-tidy-fix.yaml:109:9 — Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
  • ✅ Warning # 227 actions/untrusted-checkout-toctou/high at .github/workflows/clang-format-fix.yaml:94:9 — Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
    Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
  • ✅ Warning # 228 actions/untrusted-checkout-toctou/high at .github/workflows/python-fix.yaml:94:9 — Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
    Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
  • ✅ Warning # 229 actions/untrusted-checkout/high at .github/workflows/clang-format-fix.yaml:94:9 — Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
    Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
  • ✅ Warning # 230 actions/untrusted-checkout/high at .github/workflows/python-fix.yaml:94:9 — Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
    Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
  • ✅ Warning # 231 actions/untrusted-checkout-toctou/high at .github/workflows/cmake-format-fix.yaml:94:9 — Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
    Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
  • ✅ Warning # 232 actions/untrusted-checkout-toctou/high at .github/workflows/jsonnet-format-fix.yaml:95:9 — Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
    Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
  • ✅ Warning # 233 actions/untrusted-checkout/high at .github/workflows/cmake-format-fix.yaml:94:9 — Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
    Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
  • ✅ Warning # 234 actions/untrusted-checkout/high at .github/workflows/jsonnet-format-fix.yaml:95:9 — Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
    Checkout of untrusted code in a privileged workflow with later potential execution (event trigger: issue_comment).
  • ✅ Warning # 235 actions/untrusted-checkout/medium at .github/workflows/clang-format-check.yaml:82:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 236 actions/untrusted-checkout/medium at .github/workflows/actionlint-check.yaml:86:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 237 actions/untrusted-checkout/medium at .github/workflows/clang-tidy-check.yaml:59:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 238 actions/untrusted-checkout/medium at .github/workflows/cmake-format-check.yaml:79:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 239 actions/untrusted-checkout/medium at .github/workflows/cmake-build.yaml:159:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 240 actions/untrusted-checkout/medium at .github/workflows/header-guards-check.yaml:82:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 241 actions/untrusted-checkout/medium at .github/workflows/jsonnet-format-check.yaml:79:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 242 actions/untrusted-checkout/medium at .github/workflows/markdown-check.yaml:82:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 243 actions/untrusted-checkout/medium at .github/workflows/python-check.yaml:84:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 244 actions/untrusted-checkout/medium at .github/workflows/yaml-check.yaml:76:9 — Potential unsafe checkout of untrusted pull request on privileged workflow.
  • ✅ Warning # 245 actions/untrusted-checkout-toctou/high at .github/workflows/coverage.yaml:386:9 — Insufficient protection against execution of untrusted code on a privileged workflow (issue_comment).
  • ✅ …and 1 more alerts (see Code Scanning for the full list).

Review the full CodeQL report for details.

@github-actions

Copy link
Copy Markdown
Contributor

Clang-Tidy Check Results

Found 5761 issue(s); none are newly introduced by this patch.

All issues by check:

  • readability-identifier-naming: 2132
  • readability-redundant-member-init: 1337
  • portability-template-virtual-member-function: 575
  • performance-unnecessary-value-param: 531
  • readability-avoid-const-params-in-decls: 278
  • modernize-pass-by-value: 215
  • readability-braces-around-statements: 123
  • modernize-use-designated-initializers: 90
  • readability-convert-member-functions-to-static: 85
  • readability-const-return-type: 50
  • modernize-use-auto: 31
  • performance-move-const-arg: 29
  • performance-enum-size: 24
  • readability-qualified-auto: 24
  • readability-redundant-control-flow: 23
  • modernize-use-using: 19
  • modernize-concat-nested-namespaces: 17
  • modernize-use-equals-default: 17
  • readability-math-missing-parentheses: 16
  • modernize-avoid-c-arrays: 15
  • readability-static-definition-in-anonymous-namespace: 14
  • readability-function-size: 14
  • bugprone-branch-clone: 12
  • modernize-return-braced-init-list: 10
  • readability-isolate-declaration: 8
  • modernize-use-starts-ends-with: 8
  • readability-redundant-access-specifiers: 7
  • readability-container-size-empty: 7
  • cppcoreguidelines-special-member-functions: 7
  • modernize-use-ranges: 6
  • bugprone-throw-keyword-missing: 6
  • readability-redundant-casting: 5
  • readability-inconsistent-declaration-parameter-name: 5
  • readability-container-contains: 5
  • modernize-use-std-numbers: 3
  • modernize-use-integer-sign-comparison: 2
  • readability-use-anyofallof: 2
  • readability-else-after-return: 2
  • modernize-redundant-void-arg: 1
  • cppcoreguidelines-rvalue-reference-param-not-moved: 1
  • readability-redundant-string-init: 1
  • modernize-use-emplace: 1
  • readability-simplify-boolean-expr: 1
  • performance-avoid-endl: 1
  • modernize-make-shared: 1

See inline comments for details. Comment @phlexbot tidy-fix to auto-fix.

@greenc-FNAL
greenc-FNAL force-pushed the bugfix/includes-with-standalone-cetmodules branch from 48d673a to a71aa8a Compare June 30, 2026 14:31
@olantwin

Copy link
Copy Markdown
Contributor

Thanks, this should make packaging on conda and package managers easier!

@github-actions

Copy link
Copy Markdown
Contributor

Clang-Tidy Check Results

Found 5761 issue(s); none are newly introduced by this patch.

All issues by check:

  • readability-identifier-naming: 2132
  • readability-redundant-member-init: 1337
  • portability-template-virtual-member-function: 575
  • performance-unnecessary-value-param: 531
  • readability-avoid-const-params-in-decls: 278
  • modernize-pass-by-value: 215
  • readability-braces-around-statements: 123
  • modernize-use-designated-initializers: 90
  • readability-convert-member-functions-to-static: 85
  • readability-const-return-type: 50
  • modernize-use-auto: 31
  • performance-move-const-arg: 29
  • performance-enum-size: 24
  • readability-qualified-auto: 24
  • readability-redundant-control-flow: 23
  • modernize-use-using: 19
  • modernize-use-equals-default: 17
  • modernize-concat-nested-namespaces: 17
  • readability-math-missing-parentheses: 16
  • modernize-avoid-c-arrays: 15
  • readability-function-size: 14
  • readability-static-definition-in-anonymous-namespace: 14
  • bugprone-branch-clone: 12
  • modernize-return-braced-init-list: 10
  • readability-isolate-declaration: 8
  • modernize-use-starts-ends-with: 8
  • cppcoreguidelines-special-member-functions: 7
  • readability-redundant-access-specifiers: 7
  • readability-container-size-empty: 7
  • modernize-use-ranges: 6
  • bugprone-throw-keyword-missing: 6
  • readability-redundant-casting: 5
  • readability-inconsistent-declaration-parameter-name: 5
  • readability-container-contains: 5
  • modernize-use-std-numbers: 3
  • modernize-use-integer-sign-comparison: 2
  • readability-else-after-return: 2
  • readability-use-anyofallof: 2
  • readability-redundant-string-init: 1
  • modernize-make-shared: 1
  • cppcoreguidelines-rvalue-reference-param-not-moved: 1
  • modernize-redundant-void-arg: 1
  • performance-avoid-endl: 1
  • modernize-use-emplace: 1
  • readability-simplify-boolean-expr: 1

See inline comments for details. Comment @phlexbot tidy-fix to auto-fix.

@github-actions

Copy link
Copy Markdown
Contributor

Clang-Tidy Check Results

Found 5761 issue(s); none are newly introduced by this patch.

All issues by check:

  • readability-identifier-naming: 2132
  • readability-redundant-member-init: 1337
  • portability-template-virtual-member-function: 575
  • performance-unnecessary-value-param: 531
  • readability-avoid-const-params-in-decls: 278
  • modernize-pass-by-value: 215
  • readability-braces-around-statements: 123
  • modernize-use-designated-initializers: 90
  • readability-convert-member-functions-to-static: 85
  • readability-const-return-type: 50
  • modernize-use-auto: 31
  • performance-move-const-arg: 29
  • performance-enum-size: 24
  • readability-qualified-auto: 24
  • readability-redundant-control-flow: 23
  • modernize-use-using: 19
  • modernize-concat-nested-namespaces: 17
  • modernize-use-equals-default: 17
  • readability-math-missing-parentheses: 16
  • modernize-avoid-c-arrays: 15
  • readability-function-size: 14
  • readability-static-definition-in-anonymous-namespace: 14
  • bugprone-branch-clone: 12
  • modernize-return-braced-init-list: 10
  • readability-isolate-declaration: 8
  • modernize-use-starts-ends-with: 8
  • cppcoreguidelines-special-member-functions: 7
  • readability-container-size-empty: 7
  • readability-redundant-access-specifiers: 7
  • modernize-use-ranges: 6
  • bugprone-throw-keyword-missing: 6
  • readability-redundant-casting: 5
  • readability-inconsistent-declaration-parameter-name: 5
  • readability-container-contains: 5
  • modernize-use-std-numbers: 3
  • modernize-use-integer-sign-comparison: 2
  • readability-use-anyofallof: 2
  • readability-else-after-return: 2
  • modernize-make-shared: 1
  • readability-redundant-string-init: 1
  • performance-avoid-endl: 1
  • modernize-use-emplace: 1
  • readability-simplify-boolean-expr: 1
  • cppcoreguidelines-rvalue-reference-param-not-moved: 1
  • modernize-redundant-void-arg: 1

See inline comments for details. Comment @phlexbot tidy-fix to auto-fix.

@github-actions

Copy link
Copy Markdown
Contributor

Clang-Tidy Check Results

Found 5761 issue(s); none are newly introduced by this patch.

All issues by check:

  • readability-identifier-naming: 2132
  • readability-redundant-member-init: 1337
  • portability-template-virtual-member-function: 575
  • performance-unnecessary-value-param: 531
  • readability-avoid-const-params-in-decls: 278
  • modernize-pass-by-value: 215
  • readability-braces-around-statements: 123
  • modernize-use-designated-initializers: 90
  • readability-convert-member-functions-to-static: 85
  • readability-const-return-type: 50
  • modernize-use-auto: 31
  • performance-move-const-arg: 29
  • performance-enum-size: 24
  • readability-qualified-auto: 24
  • readability-redundant-control-flow: 23
  • modernize-use-using: 19
  • modernize-concat-nested-namespaces: 17
  • modernize-use-equals-default: 17
  • readability-math-missing-parentheses: 16
  • modernize-avoid-c-arrays: 15
  • readability-function-size: 14
  • readability-static-definition-in-anonymous-namespace: 14
  • bugprone-branch-clone: 12
  • modernize-return-braced-init-list: 10
  • readability-isolate-declaration: 8
  • modernize-use-starts-ends-with: 8
  • cppcoreguidelines-special-member-functions: 7
  • readability-container-size-empty: 7
  • readability-redundant-access-specifiers: 7
  • modernize-use-ranges: 6
  • bugprone-throw-keyword-missing: 6
  • readability-container-contains: 5
  • readability-inconsistent-declaration-parameter-name: 5
  • readability-redundant-casting: 5
  • modernize-use-std-numbers: 3
  • readability-use-anyofallof: 2
  • modernize-use-integer-sign-comparison: 2
  • readability-else-after-return: 2
  • modernize-use-emplace: 1
  • readability-simplify-boolean-expr: 1
  • cppcoreguidelines-rvalue-reference-param-not-moved: 1
  • modernize-make-shared: 1
  • modernize-redundant-void-arg: 1
  • performance-avoid-endl: 1
  • readability-redundant-string-init: 1

See inline comments for details. Comment @phlexbot tidy-fix to auto-fix.

@knoepfel
knoepfel merged commit 6a8757d into main Jun 30, 2026
39 of 41 checks passed
@knoepfel
knoepfel deleted the bugfix/includes-with-standalone-cetmodules branch June 30, 2026 16:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants