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

Could not resolve tree-sitter-typescript #196

Closed
gregberns opened this issue Jul 8, 2019 · 7 comments
Closed

Could not resolve tree-sitter-typescript #196

gregberns opened this issue Jul 8, 2019 · 7 comments

Comments

@gregberns
Copy link
Contributor

Just wanted to start playing around with the project and can't get it to build.
Installed ghc and cabal with ghcup, so I should have the most recent version. Ran the commands in the dev docs and got a dependency issue. I'm running on a Mac and ghci starts up ok. I haven't worked with cabal before so maybe theres something missing there? I've tried a couple things and this issue keeps cropping up. I saw two other similar issues, but didn't find a resolution there.

git clone [email protected]:github/semantic.git
cd semantic
script/bootstrap
cabal new-build
$ cabal new-build
HEAD is now at 83f3352 Merge pull request #32 from joshvera/bump-version-19-03-2019
HEAD is now at 84664e2 Merge pull request #7 from joshvera/reenable-tests
Resolving dependencies...
cabal: Could not resolve dependencies:
[__0] trying: semantic-0.6.0.0 (user goal)
[__1] unknown package: tree-sitter-typescript (dependency of semantic)
[__1] fail (backjumping, conflict set: semantic, tree-sitter-typescript)
After searching the rest of the dependency tree exhaustively, these were the
goals I've had most trouble fulfilling: semantic, tree-sitter-typescript
$ uname -v
Darwin Kernel Version 17.7.0: Thu Jun 21 22:53:14 PDT 2018; root:xnu-4570.71.2~1/RELEASE_X86_64
$ ghci --version
The Glorious Glasgow Haskell Compilation System, version 8.6.5
$ cabal --version
cabal-install version 2.4.1.0
compiled using version 2.4.1.0 of the Cabal library 
@robrix
Copy link
Contributor

robrix commented Jul 8, 2019

@gregberns: you might need to do a cabal new-update first. Could you give that a try please?

@gregberns
Copy link
Contributor Author

@robrix That didn't seem to help. It seemed like the package list was up to date because it didn't take very long to update. I'm going to try and re-run from within a docker container, maybe there's something with my machine.

$ cabal new-update
Downloading the latest package list from hackage.fpcomplete.com
$ cabal new-build
Resolving dependencies...
cabal: Could not resolve dependencies:
[__0] trying: semantic-0.6.0.0 (user goal)
[__1] unknown package: tree-sitter-typescript (dependency of semantic)
[__1] fail (backjumping, conflict set: semantic, tree-sitter-typescript)
After searching the rest of the dependency tree exhaustively, these were the
goals I've had most trouble fulfilling: semantic, tree-sitter-typescript

@robrix
Copy link
Contributor

robrix commented Jul 14, 2019

@gregberns: It looks like you’re pulling from stackage, rather than hackage:

$ cabal new-update
Downloading the latest package list from hackage.fpcomplete.com

vs.

$ cabal new-update
Downloading the latest package list from hackage.haskell.org

So this looks like cabal would need to be (re-)configured to use hackage.

@gregberns
Copy link
Contributor Author

gregberns commented Jul 15, 2019

@robrix thanks for the suggestion, it was a cabal issue. I kept on getting this error:

$ cabal new-update
Downloading the latest package list from hackage.haskell.org
dieVerbatim: user error (cabal: '/usr/local/opt/curl/bin/curl' exited with an error:
curl: (52) Empty reply from server
)

These instructions suggested deleting the ~/.cabal directory, which did the trick:

rm -rf ~/.cabal
cabal new-update hackage.haskell.org,HEAD
cabal new-build

Only thing was the build failed when creating the docs:


src/Data/Abstract/Evaluatable.hs:209:3: error:
    parse error on input ‘-- ^ Indicates that our evaluator wasn't able to make sense of these literals.’
    |
209 |   -- ^ Indicates that our evaluator wasn't able to make sense of these literals.
    |   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Warning: Failed to build documentation for semantic-0.6.0.0 (which is required
by exe:semantic from semantic-0.6.0.0).

@peddanet
Copy link

peddanet commented Dec 1, 2019

@gregberns Thanks a lot, this was after long search the first solution which resolved this errorneous behaviour. Now I finally can work on!

Why is there only this hidden workaround?

@robrix
Copy link
Contributor

robrix commented Dec 6, 2019

@peddanet tbh I have no idea how cabal gets into a state where it pulls only from stackage in the first place. Whatever the case, there’s not a lot we can do about configuration, except maybe document this somewhere.

@patrickt
Copy link
Contributor

patrickt commented Dec 6, 2019

@robrix I suspect it may be installed from the Haskell Platform, or some FPComplete distribution, or perhaps an odd package manager.

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

No branches or pull requests

4 participants