Skip to content

Commit

Permalink
Disable CanonicalizePath test when GetFinalPathNameByHandleW is unava…
Browse files Browse the repository at this point in the history
…ilable

When GetFinalPathNameByHandleW is unavailable, canonicalizePath falls
back to GetShortPathNameW + GetLongPathNameW, but that not always
guaranted to work. The documentation notes, for example:

> Resilient File System (ReFS) doesn't support short names. If you call
> GetShortPathName on a path that doesn't have any short names on-disk,
> the call will succeed, but will return the long-name path instead.

https://learn.microsoft.com/en-us/windows/win32/api/fileapi/nf-fileapi-getshortpathnamew

The Windows image on GitHub Actions no longer seems to support
GetShortPathNameW and so the tests have begun to fail.
  • Loading branch information
Rufflewind committed Jul 1, 2024
1 parent e8ee4d5 commit a157320
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
- { os: ubuntu-latest, ghc: 9.2.4, cabal: 3.8.1.0 }
- { os: ubuntu-latest, ghc: 9.4.3, cabal: 3.8.1.0 }
- { os: ubuntu-latest, ghc: latest, cabal: latest, cabal-package-flags: +os-string, ghc-flags: -Werror=deprecations }
- { os: windows-latest, stack: lts-12.26, stack-extra-deps: "bytestring-0.11.3.0, filepath-1.4.100.0, time-1.8.0.2, Win32-2.13.3.0", overrides: "before_prepare() { sed -i.bak -e /CreateSymbolicLinkW/d -e /GetFinalPathNameByHandleW/d configure.ac; }" }
- { os: windows-2019, stack: lts-12.26, stack-extra-deps: "bytestring-0.11.3.0, filepath-1.4.100.0, time-1.8.0.2, Win32-2.13.3.0", overrides: "before_prepare() { sed -i.bak -e /CreateSymbolicLinkW/d -e /GetFinalPathNameByHandleW/d configure.ac; }" }
- { os: windows-latest, stack: lts-17.5, stack-extra-deps: "bytestring-0.11.3.0, filepath-1.4.100.0, time-1.9.3, Win32-2.13.3.0" }
- { os: windows-latest, stack: lts-22.7, stack-extra-deps: "bytestring-0.11.5.3, filepath-1.5.2.0, os-string-2.0.2, time-1.14, Win32-2.14.0.0", stack-package-flags: "{directory: {os-string: true}, Win32: {os-string: true}}", ghc-flags: -Werror=deprecations }
runs-on: ${{ matrix.os }}
Expand Down

0 comments on commit a157320

Please sign in to comment.