InsightSoftwareConsortium / ITKRemoteModuleBuildTestPackageAction

A composite GitHub Action to build, test, and package, ITK remote modules
Apache License 2.0
3 stars 6 forks source link

Handle long module path names on Windows #20

Open tbirdso opened 1 year ago

tbirdso commented 1 year ago

See cxx failures due to long module name: https://github.com/KitwareMedical/ITKMorphologicalContourInterpolation/actions/runs/3622628311/jobs/6107569800

dzenanz commented 1 year ago

I assume we should be able to apply this trick? https://github.com/KitwareMedical/ITKUltrasound/blob/ca4e8bcb3183f591b29fbe9cf569bc08b3f0eba4/.github/workflows/build-test-package.yml#L322-L326

tbirdso commented 1 year ago

Yes, but as changing the module name obscures the directory structure and makes debugging more difficult it would be highly preferable to only change the working directory where needed, i.e. on Windows. Working to determine whether this can be done by setting environment variables to persist across Github Actions steps.

thewtex commented 1 year ago

Worth investigating going up another directory here:

https://github.com/InsightSoftwareConsortium/ITKRemoteModuleBuildTestPackageAction/blob/31f0dd5a70fab58ae5be29a3ca4ebb547d6e1621/.github/workflows/build-test-cxx.yml#L94-L96

i.e.

         file(TO_CMAKE_PATH "\$ENV{GITHUB_WORKSPACE}/../.." CTEST_DASHBOARD_ROOT) 
         file(TO_CMAKE_PATH "\$ENV{GITHUB_WORKSPACE}/" CTEST_SOURCE_DIRECTORY) 
         file(TO_CMAKE_PATH "\$ENV{GITHUB_WORKSPACE}/../../build" CTEST_BINARY_DIRECTORY) 
tbirdso commented 1 year ago

After fiddling for too long today with passing environment path names between shells (bash, command prompt, powershell) I've decided preserving non-offending module directory names is not worth more time for investigation in the short term. Preparing a PR to simply move the working source directory to ../../im as we do in the Python workflow. If there is tangible negative impact on collaborators' investigation due to path renaming then I can spend more time on this in the future.