QIICR / dcmqi

dcmqi (DICOM for Quantitative Imaging) is a free, open source C++ library for conversion between imaging research formats and the standard DICOM representation for image analysis results
https://qiicr.gitbook.io/dcmqi-guide/
BSD 3-Clause "New" or "Revised" License
240 stars 61 forks source link

Fix macos package publishing #478

Closed fedorov closed 1 year ago

fedorov commented 1 year ago

I cannot understand why, this is happening, but macos package upload errors as below:

image

This is from the failed workflow here: https://github.com/QIICR/dcmqi/actions/runs/6590088040/job/17905966802#step:12:102

This is the corresponding part of the workflow definition:

https://github.com/QIICR/dcmqi/blob/12032e31aeb9c2e4cd9472520d134f7da247909d/.github/workflows/cmake-macos.yml#L99-L106

which is exactly the same as we use on linux:

https://github.com/QIICR/dcmqi/blob/12032e31aeb9c2e4cd9472520d134f7da247909d/.github/workflows/cmake-linux.yml#L46-L56

@jcfr do you have any thoughts on this?

michaelonken commented 1 year ago

Maybe the file name with wildcards is not correct and resolves to an empty string. At least I think the error message would look like this.

I would add a step after the build step which does ls -R on the build directory in order to see whether the ZIP is at the expected position with correct naming.

fedorov commented 1 year ago

@michaelonken note that here: https://github.com/QIICR/dcmqi/actions/runs/6590088040/job/17905966802#step:11:28 it seems to indicate the package name is consistent with the expectations of the wildcard:

CPack: - package: /Users/runner/work/dcmqi/dcmqi/dcmqi-build/dcmqi-build/dcmqi-1.2.5-mac-20231020-12032e3.tar.gz generated.

fedorov commented 1 year ago

Sorry, I didn't realize my comment would close the issue!

fedorov commented 1 year ago

No, that didn't fix the issue. @jcfr hope you have ideas what's gong on!

michaelonken commented 1 year ago

Another guess:

Multiline separators are missing for this command, i.e. end of line backslashes like in

ci_addons publish_github_release QIICR/dcmqi \
    --prerelease-packages "build/dcmqi-build/dcmqi-*-linux-*.tar.gz" \

...

fedorov commented 1 year ago

@michaelonken you were right - that was it! https://github.com/QIICR/dcmqi/actions/runs/6598744176/job/17927016620 succeeded!

I thought I specifically looked and made it the same as in linux, but I messed it up!

@jcfr I am closing this one, but if you ever get a chance to review and suggest where best practices can be improved, this would of course be most welcomed contribution!