-
-
Notifications
You must be signed in to change notification settings - Fork 410
Set the XDG_CACHE_HOME for tests #4572
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
1a34302 to
7df2e36
Compare
soulomoon
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. But ghcide test is not running for this PR, do you know why it is skipped
|
https://github.com/haskell/haskell-language-server/blob/master/.github/workflows/test.yml#L51 Outdated skip in CI. Gonna fix that! |
|
Test failures all look genuine, so more investigation is required. |
3be9351 to
8dcd861
Compare
| -- specially in tests it's common to have lots of nameless modules | ||
| -- mkHomeModLocation will map them to the same hi/hie locations | ||
| then mkHomeModLocation dflags (pathToModuleName fp) fp | ||
| then mkHomeModLocation dflags mod fp |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems to be causing long-path issues on windows.
I am unsure how relevant this still is... Anybody an idea?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is unfortunately a case we have to support, so this change can't be applied as is.
7729e73 to
a7ad2c6
Compare
bb55dd7 to
b27f3d2
Compare
|
Is it blocking by the long path issue for windows? Can we shrink the test cache dir path? |
|
@soulomoon Yes, it is blocking :( I have no idea how to further shrink down the test cache dir path, without either reimplementing |
|
That seems to be ghc's issue ? see https://gitlab.haskell.org/ghc/ghc/-/issues/13373 @fendor So to workaround this, we might have to customize our |
|
I am not sure if the issue is still relevant |
This makes sure each test run is independent. Makes the tests * iface-error-test-1 * iface-th-test less flaky locally. Should not have any effect on the CI flakiness issue. --- Fix test cases to work with the temporary `XDG_CACHE_HOME` Some tests were launching additional HLS instances for the tests. Fixed, which should make the test slightly faster.
Ghcide test infrastructure was refactored to depend on `hls-test-utils`.
c873852 to
f5371bc
Compare
17c54f8 to
b625c58
Compare
Adds support for the `HLS_TEST_ROOTDIR` which allows to overwrite the location for the test case artifacts.
b625c58 to
88c5687
Compare
|
The lazy solution to set a shorter test directory on windows seems to be working. Finally! @guibou, @soulomoon perhaps a final review? Otherwise, Ill just merge it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Look good to me, I can't reproduce the long path problem in a local windows machine, so it must be a CI machine problem. So set a shorter path in .github/actions/setup-build/action.yml look like a good idea to me.


This makes sure each test run is independent.
Makes the tests
less flaky locally. On my machine, these tests were consistently failing after the first successful execution (due to caching the
hiedbafaict.)Should not have any effect on the CI flakiness issue.