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

ghcjs-dom 0.9.4 somehow causes websocket failure in CodeWorld #97

Open
cdsmith opened this issue Jun 20, 2020 · 2 comments
Open

ghcjs-dom 0.9.4 somehow causes websocket failure in CodeWorld #97

cdsmith opened this issue Jun 20, 2020 · 2 comments

Comments

@cdsmith
Copy link

cdsmith commented Jun 20, 2020

I apologize in advance for a terrible bug report, but I wanted to document what I know about this so far. Building codeworld-api with GHCJS and ghcjs-dom 0.9.4 causes use of websockets to fail as described in google/codeworld#1382. The same does not occur when building against ghcjs-dom 0.9.2 (the previous version on hackage).

The weird thing is that codeworld-api isn't using ghcjs-dom for websockets. It's using the JavaScript.Web.WebSocket module from ghcjs-base, which doesn't depend on ghcjs-dom at all. So I don't understand the mechanism behind the failure. Yet the bug definitely correlates with that ghcjs-dom version.

I can try to construct a smaller test case this weekend. Until then, the relevant code is in https://github.com/google/codeworld/blob/master/codeworld-api/src/CodeWorld/Driver.hs

@3noch
Copy link

3noch commented Jun 21, 2020

I doubt it's related but I'll take this opportunity to point out that ghcjs has a rather serious bug fixed by ghcjs/ghcjs#788. I'd suggest at least testing that when you encounter mysterious errors.

@cdsmith
Copy link
Author

cdsmith commented Jun 21, 2020

@3noch Thanks, that is good to know. I also doubt it's related to this issue, but it is worth fixing. I already build a patched GHCJS for CodeWorld, so it will be easy to apply this patch, as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants