Skip to content
This repository has been archived by the owner on Oct 7, 2020. It is now read-only.

failed to find requested hint files only on lts-12.* #872

Closed
leshow opened this issue Oct 12, 2018 · 17 comments · Fixed by #1573
Closed

failed to find requested hint files only on lts-12.* #872

leshow opened this issue Oct 12, 2018 · 17 comments · Fixed by #1573

Comments

@leshow
Copy link

leshow commented Oct 12, 2018

2018-10-12 17:40:45.715944045 [ThreadId 4] - Current directory:/home/leshow/dev/haskell/haskell-programming-book/ProgrammingHaskell_Hutton
2018-10-12 17:40:45.742631268 [ThreadId 13] - Using stack GHC version
Using hie version: Version 0.2.2.0, Git revision 5d1d825880196eddbca4b1d12a60713f247c2a64 (1961 commits) x86_64 ghc-8.4.3
2018-10-12 17:40:45.882557696 [ThreadId 13] - requestDiagnostics: no diagFunc for:DiagnosticOnOpen
hie-8.4.3: user error (Failed to find requested hint files:
  /usr/bin/data/hlint.yaml
)

/usr/bin/data does not exist

This error only happens on 12.x LTS, 11.9 and others work fine.

I've installed from haskell-ide-engine-git in the AUR. Does anyone else have this issue? Any ideas?

@owickstrom
Copy link

Had the same issue, but where it was looking in ~/.stack/compiler-tools for the hint file. Deleted the hie executables from the compiler-tools directory and reinstalled, which solved it for me.

@leshow
Copy link
Author

leshow commented Oct 15, 2018

@owickstrom I'll give that a shot thanks. Are you saying it was looking in ~/.stack/compiler-tools instead of /usr/bin/data though ?

@owickstrom
Copy link

@leshow Yeah, exactly.

@leshow
Copy link
Author

leshow commented Oct 16, 2018

I don't have a ~/.stack/compiler-tools, locate can't find any folder by that name either.

@leshow
Copy link
Author

leshow commented Oct 16, 2018

Ah okay, it appears (after removing hie) that there were a bunch of binaries still in ~/.local/bin I've just removed these, and am re-installing hie. I'll close the thread if that fixes things

@leshow
Copy link
Author

leshow commented Oct 16, 2018

I re-installed and have now broken all of hie. I get the same error on 12.x LTS and on 11.x or lower I get:

hie-8.2.2: Could not find $libexecdir/cabal-helper-wrapper

If you are a cabal-helper developer you can set the environment variable
`cabal_helper_libexecdir' to override $libexecdir[1]. The following will
work in the cabal-helper source tree:

    $ export cabal_helper_libexecdir=$PWD/dist/build/cabal-helper-wrapper

[1]: /var/cache/pacman/pkg/haskell-ide-engine-git19859/haskell-ide-engine-git/src/haskell-ide-engine/.stack-work/install/x86_64-linux-tinfo6/lts-11.18/8.2.2/libexec/x86_64-linux-ghc-8.2.2/cabal-helper-0.8.1.0

If you don't know what I'm talking about something went wrong with your
installation. Please report this problem here:

    https://github.com/DanielG/cabal-helper/issues

The path in /var/cache doesn't actually exist it looks like, so that's helpful

@lukel97
Copy link
Collaborator

lukel97 commented Oct 17, 2018

A quick workaround:

mkdir ~/.local/bin/data
touch ~/.local/bin/data/hlint.yaml

I think it's weird that hlint throws an exception when there's no global file. It could be hie messing up when its invoking it

@alanz
Copy link
Collaborator

alanz commented Dec 24, 2018

TODO: update README

@jarcane
Copy link

jarcane commented Feb 26, 2019

I am having this same problem. It complains about the missing hlint file, and if I do the workaround @bubba suggests I get a similar error to @leshow :

hie-8.6.3: Could not find $libexecdir/cabal-helper-wrapper

If you are a cabal-helper developer you can set the environment variable
`cabal_helper_libexecdir' to override $libexecdir[1]. The following will
work in the cabal-helper source tree:

    $ export cabal_helper_libexecdir=$PWD/dist/build/cabal-helper-wrapper

[1]: /home/annaia/projects/haskell-ide-engine/.stack-work/install/x86_64-linux-tinfo6/lts-13.0/8.6.3/libexec/x86_64-linux-ghc-8.6.3/cabal-helper-0.9.0.0
/home/annaia/projects/haskell-ide-engine/.stack-work/install/x86_64-linux-tinfo6/lts-13.0/8.6.3/libexec/x86_64-linux-ghc-8.6.3/cabal-helper-0.9.0.0/cabal-helper-wrapper
junk/build/cabal-helper-wrapper/cabal-helper-wrapper
/home/annaia/projects/haskell-ide-engine/.stack-work/install/x86_64-linux-tinfo6/lts-13.0/8.6.3/bin/cabal-helper-wrapper

If you don't know what I'm talking about something went wrong with your
installation. Please report this problem here:

    https://github.com/DanielG/cabal-helper/issues

hie --version: Version 0.5.0.0, Git revision c4a9e7c (2382 commits) x86_64 ghc-8.6.3

@alanz
Copy link
Collaborator

alanz commented Mar 1, 2019

@jarcane the current version of hie is 0.6.0.0, and it did update hlint.

Please re-install and try again.

@alanz alanz modified the milestones: 2019-02, 2019-03 Mar 2, 2019
@LinArcX
Copy link

LinArcX commented Mar 5, 2019

Still same issue with arch linux and install bunch of packages like hoogle, hlint. but still complain about hlint.yaml. I follow @owickstrom and @bubba . but nothing changed.

Using hie version: Version 0.6.0.0, Git revision 239d07da8a3a7f80a4f0acef287256aae4cc2361 (2402 commits) x86_64 ghc-8.6.3
Using hoogle db at: /home/linarcx/.hoogle/default-haskell-5.0.17.hoo
hie-8.6.3: user error (Failed to find requested hint files:
  /usr/bin/data/hlint.yaml
)

@leshow
Copy link
Author

leshow commented Mar 5, 2019

@LinArcX don't install any other packages from AUR, afaik hie provides its own versions of the required packages

@LinArcX
Copy link

LinArcX commented Mar 6, 2019

@leshow:
I installed hie binary version from archlinuxcn.
archlinuxcn/repo#1044
And stack binary version. (without installing ghc and it's whole bunch of libraries)
archlinuxcn/repo#882
Is it OK?

@lukel97
Copy link
Collaborator

lukel97 commented Mar 6, 2019

hie-8.6.3: user error (Failed to find requested hint files:
  /usr/bin/data/hlint.yaml
)

This is one of the issues we're having with generating our own static binaries: hlint relies on data-files which currently there's not a great way of bundling with a binary, and similarly for cabal-helper
For now though touch /usr/bin/data/hlint.yaml should fix it 😬

@LinArcX
Copy link

LinArcX commented Mar 7, 2019

@bubba nothing changed.

@alanz alanz modified the milestones: 2019-03, 2019-04 Apr 6, 2019
@fendor
Copy link
Collaborator

fendor commented Apr 14, 2019

This should be different now, hie does no longer choke on that, however, hlint does not work if there is no hlint.yaml, or in general, when its data-files are missing. The issue #1143 aims to solve this problem as a whole, once we have decision for it.

@alanz alanz removed this from the 2019-04 milestone May 4, 2019
@jneira
Copy link
Member

jneira commented Jan 14, 2020

Closed by #1143: hlint data files could be placed in a subfolder data in the same directory where the hie executable is. We'll enforce that in the release artifacts.

Only left update docs.

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

Successfully merging a pull request may close this issue.

9 participants