Skip to content
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

Non-deterministic CI test failures #1430

Closed
Ailrun opened this issue Feb 23, 2021 · 12 comments · Fixed by #1479
Closed

Non-deterministic CI test failures #1430

Ailrun opened this issue Feb 23, 2021 · 12 comments · Fixed by #1479
Labels
CI Continuous integration component: ghcide type: bug Something isn't right: doesn't work as intended, documentation is missing/outdated, etc..

Comments

@Ailrun
Copy link
Member

Ailrun commented Feb 23, 2021

Recently, test CI starts to fail because of

Exception: Language server unexpectedly terminated

or

Exception: fd:6: hPutBuf: resource vanished (Broken pipe)

in a non-deterministic manner.

I suspect that this issue has been introduced with lsp-1.0 update (it started to happen since then, if my memory is correct), but haven't found any obvious clues.

@Ailrun Ailrun added CI Continuous integration type: testing labels Feb 23, 2021
@Ailrun Ailrun changed the title Non-deterministic test failures Non-deterministic CI test failures Feb 23, 2021
@jneira jneira added the type: bug Something isn't right: doesn't work as intended, documentation is missing/outdated, etc.. label Feb 24, 2021
@jneira
Copy link
Member

jneira commented Feb 24, 2021

It seems they are more frequent in windows, i remember to fix similar errors in lsp-test some time ago, which process handling was assuming a linux system

@Ailrun

This comment has been minimized.

@jneira

This comment has been minimized.

@jneira
Copy link
Member

jneira commented Mar 2, 2021

ci results are highly inestable lately, due to the mentioned false negatives and errors in the bench job 😟

@Ailrun

This comment has been minimized.

@wz1000
Copy link
Collaborator

wz1000 commented Mar 2, 2021

The cabal file for that test lists both KnownNat and RecordDot as part of the component.

library
  build-depends: base, ghc-typelits-knownnat, record-dot-preprocessor,
          record-hasfield
  exposed-modules: KnownNat, RecordDot
  hs-source-dirs: .

Obviously this leads to the non-deterministic failures observed. Someone should split this up into two cabal projects.

@pepeiborra
Copy link
Collaborator

What about this one:

    type-definition
      Saturated data con:                                                                                 FAIL
        Exception: fd:71: hPutBuf: resource vanished (Broken pipe)
      Polymorphic variable:                                                                               FAIL
        Exception: fd:107: hPutBuf: resource vanished (Broken pipe)
  simple plugin:                                                                                          ghcide-tests: Maybe.fromJust: Nothing
CallStack (from HasCallStack):
  error, called at libraries/base/Data/Maybe.hs:148:21 in base:Data.Maybe
  fromJust, called at src/Language/LSP/Test/Decoding.hs:87:15 in lsp-test-0.13.0.0-f38a659f3ed5e1ec1cde1ce88a73f023eeed40e148f97626f31f53fa01ea14e5:Language.LSP.Test.Decoding

@wz1000
Copy link
Collaborator

wz1000 commented Mar 2, 2021

Do you have the logs from that?

@mergify mergify bot closed this as completed in #1479 Mar 2, 2021
@Ailrun
Copy link
Member Author

Ailrun commented Mar 2, 2021

It's not fully resolved yet.

@Ailrun Ailrun reopened this Mar 2, 2021
@berberman
Copy link
Collaborator

I observed a new one, which happens randomly in many test cases

https://paste.xinu.at/TtbZ/
https://github.com/haskell/haskell-language-server/runs/2127845970

Received an illegal message between the initialize request and response:
{
    "id": 0,
    "method": "window/workDoneProgress/create",
    "params": {
        "token": "5"
    },
    "jsonrpc": "2.0"
}

@pepeiborra
Copy link
Collaborator

After landing #1651 we now see some tests randomly failing with the error below, potentially impacting all tests and OS (although so far I have only observed it in Windows):

Error:  Fatal error in server thread: SQLite3 returned ErrorBusy while attempting to perform step: database is locked
3083
****

https://github.com/haskell/haskell-language-server/pull/1667/checks?check_run_id=2269170992

@wz1000 volunteered to look into this eventually. @wz1000 is there any workaround we can apply in the meantime?

@jneira
Copy link
Member

jneira commented Jun 22, 2021

It seems those failures are gone for now, we can open a new one if they strikes back

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI Continuous integration component: ghcide type: bug Something isn't right: doesn't work as intended, documentation is missing/outdated, etc..
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants