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

Sample App won't build because of ghcjs-base and github timeout #719

Open
joelmccracken opened this issue Feb 14, 2023 · 15 comments
Open

Sample App won't build because of ghcjs-base and github timeout #719

joelmccracken opened this issue Feb 14, 2023 · 15 comments

Comments

@joelmccracken
Copy link
Contributor

joelmccracken commented Feb 14, 2023

Describe the bug
I don't believe this is a bug with miso itself, but I believe miso needs to update a dependency somewhere/somehow to fix it:

When i try to build the sample app, it fails. Checking the log, I get the following:

Asked somewhere else and someone shared this article: https://github.blog/2021-09-01-improving-git-protocol-security-github/

Locally, I can see the issue:

  • git clone git://github.com/ghcjs/ghcjs-base times out
  • git clone http://github.com/ghcjs/ghcjs-base works fine

To Reproduce
Steps to reproduce the behavior:

On a fresh machine, try to build the sample app.

@dmjio
Copy link
Owner

dmjio commented Feb 14, 2023

Are you using cachix as described in README.md ? Using the cached deps. is usually a better experience.

@joelmccracken
Copy link
Contributor Author

Ah, no, I don't think so. This was a new machine and I haven't set up cachix on it.

I'll try that and report back, hopefully that will unblock me. Though this still seems like an issue?

@dmjio
Copy link
Owner

dmjio commented Feb 15, 2023

It is an issue yea, but nixpkgs might not have the old GHCJS (which just happens to be the most stable). So upgrading isn't an option it seems until the latest GHC supports FFI for its new JS / WASM backends.

@dmjio
Copy link
Owner

dmjio commented Feb 15, 2023

@joelmccracken definitely let me know if cachix does / doesn't work for you. Cheers 🍻

@joelmccracken
Copy link
Contributor Author

Just tried it, and it built!

Not sure if you want to keep this open or not since its solved for me, but it might save someone else some time who decides to try it during this weird interim state.

@dmjio
Copy link
Owner

dmjio commented Feb 16, 2023

Let’s just hope Google indexes it for others ;)

feel free to join the slack if you have additional questions.

https://haskell-miso.slack.com/

@dmjio dmjio closed this as completed Feb 16, 2023
@joelmccracken
Copy link
Contributor Author

Can I get an invitation? It seems that to create an account I need to have a @haskell-miso.com email address

@caryoscelus
Copy link

i've just run into this issue and honestly i don't find using binary cache can be considered a solution. is there any other possible workaround? (i'm fairly new to nix inner workings, but i'm sure it should be possible to extract required ghcjs package and update it to not use git://)

if there's no workaround, what is the estimate of new ghcjs with necessary features being available?

@dmjio
Copy link
Owner

dmjio commented Mar 14, 2023

Using the binary cache is the fix for now. Regarding when miso will be updated to use the new JS / wasm backend I think it depends on when FFI is supported, among other things (template Haskell).

@caryoscelus
Copy link

Using the binary cache is the fix for now

unfortunately that sounds like the whole setup is effectively not fully open source :(

https://gitlab.haskell.org/ghc/ghc/-/wikis/javascript-backend#current-status-and-supported-features

thanks

@dmjio
Copy link
Owner

dmjio commented Mar 14, 2023

There’s no corporate pay wall, but if you build at the old hash with the old version of nix it should be reproducible.

@dmjio dmjio reopened this Mar 14, 2023
@dmjio
Copy link
Owner

dmjio commented Mar 14, 2023

@caryoscelus it does seem like foreign imports are supported, but not exports. This should be okay, I will get back to you as to how long it would take to update.

@dmjio
Copy link
Owner

dmjio commented Mar 15, 2023

@caryoscelus If you'd prefer we can use our own binary cache, with our own s3 bucket and sign our own packages - cachix just makes this more convenient and our closure fits in the free tier. Furthermore, there are plans to upgrade, it's just that the JS backend has no binary distributions yet, so users would need to build / maintain their own GHC.

@caryoscelus
Copy link

@dmjio for my purposes i want to be able to build everything myself so different cache doesn't make much difference. right now i'm still evaluating whether to use Haskell&Miso or PureScript, though, since latter seems to have easier support for 'advanced' browser features (WebRTC, IndexedDB)

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

3 participants