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

Unable to use purescript-d3 on current purescript #20

Open
arafangion opened this issue Aug 6, 2016 · 6 comments
Open

Unable to use purescript-d3 on current purescript #20

arafangion opened this issue Aug 6, 2016 · 6 comments

Comments

@arafangion
Copy link

arafangion commented Aug 6, 2016

When I do the following:

pulp --version
Pulp version 9.0.1
psc version 0.9.1 using /usr/local/bin/psc

pulp init # For a new project
bower install purescript-d3 --save

I get conflicting dependencies as follows:

Unable to find a suitable version for purescript-eff, please choose one by typing one of the >numbers below:

  1. purescript-eff#^0.1.0 which resolved to 0.1.2 and is required by purescript-st#0.1.1
  2. purescript-eff#^1.0.0 which resolved to 1.0.0 and is required by purescript-console#1.0.0

And neither of these options work.

I suspect that using the master branch will work, however bower currently seems to use v0.7.0, which still exhibits this issue.

Update: Yes, using the master build does work, although it builds with 17 warnings, all of which are much the same:

Warning 1 of 17:

in module Graphics.D3.Interpolate
at /Users/arahael/dev/tmp/bower_components/purescript-d3/src/Interpolate.purs line 8, column 1 - line 8, column 28

No type declaration was provided for the top-level declaration of ffi.
It is good practice to provide type declarations as a form of documentation.
The inferred type of ffi was:

 forall a. Array String -> String -> a

in value declaration ffi

See https://github.com/purescript/purescript/wiki/Error-Code-MissingTypeDeclaration for more information,
or to contribute content related to this warning.

@arafangion
Copy link
Author

arafangion commented Aug 6, 2016

I am too new to purescript, javascript, or d3 in general to fix this myself, however I'm happy to consider writing a patch if someone is willing to critically review it and fix the inevitable mistakes.

The actual fixes seem to involve mainly a simple matter of adding types to all the 17 functions.

This also probably depend the status of #17 however I wouldn't know what the impact of those changes would be here. Some guidance would be appreciated.

@nwolverson
Copy link
Contributor

Other than the warnings, think this just needs tagged as release, seems to be working fine for me on 0.9.x - @pelotom would you mind tagging? Maybe also worth pushing to pursuit.

@pelotom
Copy link
Owner

pelotom commented Sep 28, 2016

Tagged the latest. I'm happy to take a PR which addresses the warnings.

@pelotom
Copy link
Owner

pelotom commented Sep 28, 2016

Also published to Pursuit

@BebeSparkelSparkel
Copy link

can this be added to https://github.com/purescript/package-sets

@dustin
Copy link

dustin commented Aug 28, 2021

I think they may have broken it again. I was hoping to learn purescript this evening with d3 as the first library I wanted to use, but once I got it loaded as a package set, it failed with:

  at .spago/d3/v0.9.0/src/Time.purs:2:1 - 2:2 (line 2, column 1 - line 2, column 2)

    Unable to parse module:
    Illegal whitespace character U+0009

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

5 participants