Repository navigation
Fix Windows NSIS packaging: invalid CMake escape breaks nightly build - #9991
Conversation
…FILE
TO_NATIVE_PATH produced a Windows path with literal backslashes (e.g.
D:\a\OpenMS\OpenMS\build\...\Cfg_Settings.nsh, since GitHub Actions
checks out under D:\a\<owner>\<repo>). CPack re-serializes this CPACK_
variable into a quoted string in the generated CPackConfig.cmake, where
"\a" is not a valid CMake string escape, breaking the nightly Windows
package step ("Invalid character escape '\a'."). Use the forward-slash
CMake path instead, consistent with CPack's own path variables
(CPACK_TOPLEVEL_DIRECTORY etc.) used in the same NSIS template; NSIS's
!include accepts forward slashes.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 4 included reviews per hour; 3 remain after this review. 📝 WalkthroughWalkthroughThe NSIS packaging configuration now stores Changes
Suggested reviewers: Poem
Merge Risk: ⚪ Minimal · up to The change makes the generated Windows packaging path CMake-safe by using forward slashes, preventing the nightly NSIS configuration parse failure. No actionable merge-blocking risk remains beyond normal checks and review. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
Full details: Docstring CoverageExplanation No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0 files. (1 skipped: 1 unsupported.) ✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
- -feat_dir (ProteomicsLFQ) and the imzML dropped-array warning shipped without their PR citation (OpenMS#9989, OpenMS#10002). - The Biosaur2/FAIMS fix entry cited only the tracking issue (OpenMS#9980), not the merged PR (OpenMS#9996). - No entry existed for the NSIS Cfg_Settings.nsh path fix (OpenMS#9978, OpenMS#9991) or the multi-arch container deploy race fix (OpenMS#9951, OpenMS#9954).
…#10014) Adds entries for PRs merged after the last CHANGELOG update (#9995, #10009, #10010, #10012) that were not yet reflected in the file, and fills in missing PR references on the FeatureFinderIdentification external-path removal. Also rewrites the NSIS Cfg_Settings.nsh entry, whose previously documented fix (#9978, #9991) turned out to be insufficient and was superseded by the definitive fix in #10009. Co-authored-by: Claude <[email protected]>
Description
The nightly
Releaseworkflow's Windows (cl.exe) packaging job has been failing every night since a prior fix (159f6f1, merged via #9985... actually via develop directly on 2026-08-28) changed howCPACK_OPENMS_CFG_SETTINGS_FILEis computed:Root cause:
cmake/package_nsis.cmakeusedfile(TO_NATIVE_PATH ...)to compute the absolute path to the generatedCfg_Settings.nsh, producing a Windows path with literal backslashes (GitHub Actions checks out the repo underD:\a\<owner>\<repo>, so the path contains\a\OpenMS\...). This value is aCPACK_-prefixed variable, so CPack re-serializes it into a quoted CMake string literal inside the generatedCPackConfig.cmake. CMake's string parser does not recognize\aas a valid escape sequence, so parsing that generated file fails outright, which fails the whole packaging step on every matrix job that produces an NSIS installer (the nightlyReleaseworkflow onwindows-2025/cl.exe).Fix: build the path with forward slashes instead (
"${PROJECT_BINARY_DIR}/Cfg_Settings.nsh"), the same convention already used by CPack's own path variables (e.g.CPACK_TOPLEVEL_DIRECTORY) in the same NSIS template (cmake/Windows/NSIS.template.in). NSIS's!includeaccepts forward-slash paths just fine, so this avoids the backslash-escaping problem entirely without reintroducing the original bug (a hardcoded relative!includepath that broke whenCPACK_PACKAGE_DIRECTORYis redirected to a short path).This is not a workaround (skipping the packaging step, disabling the check, etc.) — it fixes the actual path being generated so
cpack -G NSIScan parse its own generated config file.Checklist
Generated by Claude Code
Summary by CodeRabbit