I think this is the nondeterministic compilation of GHC. The same inputs can lead to different package hashes, which makes it possible that the binary cache and your locally built results are incompatible. It is a quite annoying property of GHC in the context of Nix.