{"action":"created","issue":{"url":"https://api.github.com/repos/NixOS/nixpkgs/issues/46453","repository_url":"https://api.github.com/repos/NixOS/nixpkgs","labels_url":"https://api.github.com/repos/NixOS/nixpkgs/issues/46453/labels{/name}","comments_url":"https://api.github.com/repos/NixOS/nixpkgs/issues/46453/comments","events_url":"https://api.github.com/repos/NixOS/nixpkgs/issues/46453/events","html_url":"https://github.com/NixOS/nixpkgs/pull/46453","id":358421508,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE0MTY5OTk0","number":46453,"title":"haskellPackages.shellFor: Fix ghc calls","user":{"login":"Infinisil","id":20525370,"node_id":"MDQ6VXNlcjIwNTI1Mzcw","avatar_url":"https://avatars0.githubusercontent.com/u/20525370?v=4","gravatar_id":"","url":"https://api.github.com/users/Infinisil","html_url":"https://github.com/Infinisil","followers_url":"https://api.github.com/users/Infinisil/followers","following_url":"https://api.github.com/users/Infinisil/following{/other_user}","gists_url":"https://api.github.com/users/Infinisil/gists{/gist_id}","starred_url":"https://api.github.com/users/Infinisil/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Infinisil/subscriptions","organizations_url":"https://api.github.com/users/Infinisil/orgs","repos_url":"https://api.github.com/users/Infinisil/repos","events_url":"https://api.github.com/users/Infinisil/events{/privacy}","received_events_url":"https://api.github.com/users/Infinisil/received_events","type":"User","site_admin":false},"labels":[{"id":737642262,"node_id":"MDU6TGFiZWw3Mzc2NDIyNjI=","url":"https://api.github.com/repos/NixOS/nixpkgs/labels/10.rebuild-darwin:%200","name":"10.rebuild-darwin: 0","color":"eeffee","default":false},{"id":737642408,"node_id":"MDU6TGFiZWw3Mzc2NDI0MDg=","url":"https://api.github.com/repos/NixOS/nixpkgs/labels/10.rebuild-linux:%200","name":"10.rebuild-linux: 0","color":"eeffee","default":false},{"id":99513706,"node_id":"MDU6TGFiZWw5OTUxMzcwNg==","url":"https://api.github.com/repos/NixOS/nixpkgs/labels/6.topic:%20haskell","name":"6.topic: haskell","color":"fef2c0","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":14,"created_at":"2018-09-09T23:02:33Z","updated_at":"2018-09-23T21:13:28Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/NixOS/nixpkgs/pulls/46453","html_url":"https://github.com/NixOS/nixpkgs/pull/46453","diff_url":"https://github.com/NixOS/nixpkgs/pull/46453.diff","patch_url":"https://github.com/NixOS/nixpkgs/pull/46453.patch"},"body":"###### Motivation for this change\r\nThis cost me a couple hours to figure out. The original error was\r\n```\r\nGot error while processing diagnostics: <command line>: cannot satisfy -package-id hnix-0.5.2-5hMz8sQY4ky2OCdjsvbD9J\r\n```\r\nfrom ghc-mod via [HIE](https://github.com/haskell/haskell-ide-engine). After a very long time of debugging, I finally figured out that the reason was that `shellFor` doesn't run any `shellHook` that sets up the correct `NIX_GHC*` env vars to have it find stuff. This PR just does a dirty fast fix by copying part of the logic in `generic-builder.nix`, please don't merge it like this.\r\n\r\nPing @peti @ryantm @basvandijk @domenkozar (Ping the people I annoyed for hours in #haskell-ide-engine because of this: @alanz @DanielG)\r\n\r\n###### Things done\r\n\r\n<!-- Please check what applies. Note that these are not hard requirements but merely serve as information for reviewers. -->\r\n\r\n- [ ] Tested using sandboxing ([nix.useSandbox](http://nixos.org/nixos/manual/options.html#opt-nix.useSandbox) on NixOS, or option `sandbox` in [`nix.conf`](http://nixos.org/nix/manual/#sec-conf-file) on non-NixOS)\r\n- Built on platform(s)\r\n   - [ ] NixOS\r\n   - [ ] macOS\r\n   - [ ] other Linux distributions\r\n- [ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside [nixos/tests](https://github.com/NixOS/nixpkgs/blob/master/nixos/tests))\r\n- [ ] Tested compilation of all pkgs that depend on this change using `nix-shell -p nox --run \"nox-review wip\"`\r\n- [ ] Tested execution of all binary files (usually in `./result/bin/`)\r\n- [ ] Determined the impact on package closure size (by running `nix path-info -S` before and after)\r\n- [ ] Fits [CONTRIBUTING.md](https://github.com/NixOS/nixpkgs/blob/master/.github/CONTRIBUTING.md).\r\n\r\n---\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/NixOS/nixpkgs/issues/comments/423848372","html_url":"https://github.com/NixOS/nixpkgs/pull/46453#issuecomment-423848372","issue_url":"https://api.github.com/repos/NixOS/nixpkgs/issues/46453","id":423848372,"node_id":"MDEyOklzc3VlQ29tbWVudDQyMzg0ODM3Mg==","user":{"login":"ElvishJerricco","id":1365692,"node_id":"MDQ6VXNlcjEzNjU2OTI=","avatar_url":"https://avatars0.githubusercontent.com/u/1365692?v=4","gravatar_id":"","url":"https://api.github.com/users/ElvishJerricco","html_url":"https://github.com/ElvishJerricco","followers_url":"https://api.github.com/users/ElvishJerricco/followers","following_url":"https://api.github.com/users/ElvishJerricco/following{/other_user}","gists_url":"https://api.github.com/users/ElvishJerricco/gists{/gist_id}","starred_url":"https://api.github.com/users/ElvishJerricco/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ElvishJerricco/subscriptions","organizations_url":"https://api.github.com/users/ElvishJerricco/orgs","repos_url":"https://api.github.com/users/ElvishJerricco/repos","events_url":"https://api.github.com/users/ElvishJerricco/events{/privacy}","received_events_url":"https://api.github.com/users/ElvishJerricco/received_events","type":"User","site_admin":false},"created_at":"2018-09-23T21:13:28Z","updated_at":"2018-09-23T21:13:28Z","author_association":"CONTRIBUTOR","body":"What's blocking this? Can this be merged?"}}
{"actor":{"display_login":"ElvishJerricco"}}