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

"The following package identifiers were not found in your indices" #3033

Closed
sjakobi opened this issue Mar 1, 2017 · 19 comments
Closed

"The following package identifiers were not found in your indices" #3033

sjakobi opened this issue Mar 1, 2017 · 19 comments

Comments

@sjakobi
Copy link
Member

sjakobi commented Mar 1, 2017

~ $ stack --resolver nightly build tasty-stats
Selected resolver: nightly-2017-03-01
Selected mirror https://s3.amazonaws.com/hackage.fpcomplete.com/                                 
Downloading timestamp                                                                            
No updates to your package list were found                                                       
Updating package index Hackage (mirrored at https://s3.amazonaws.com/hackage.fpcomplete.com/) ...The following package identifiers were not found in your indices: tasty-stats-0.2.0.2

This might be related to the recent Hackage maintenance or the S3 downtime. I have notified the Hackage maintainers here.

It would be nice if stack could handle this better or at least make a suggestion like "report a bug".

@mgsloan
Copy link
Contributor

mgsloan commented Mar 7, 2017

I could indeed reproduce this when you opened it, however, it seems to have resolved itself! Indeed likely due to something like hackage maintenance or s3 downtime.

@mgsloan mgsloan closed this as completed Mar 7, 2017
@sjakobi
Copy link
Member Author

sjakobi commented Mar 12, 2017

I'm seeing similar exceptions once more:

~/s/hackage-server (master|✔) $ stack init --ignore-subdirs --force
Looking for .cabal or package.yaml files to use to init the project.
Using cabal packages:
- hackage-server.cabal

Selecting the best among 10 snapshots...

Missing some cabal revision files, updating indices
Selected mirror https://s3.amazonaws.com/hackage.fpcomplete.com/                                 
Downloading timestamp                                                                            
No updates to your package list were found                                                       
Did not find .cabal file for safe-exceptions-checked-0.1.0 with SHA of 2d07e15162937261823e35786206c8a218db8ae1 in tarball-based cache
Selected mirror https://s3.amazonaws.com/hackage.fpcomplete.com/                                 
Downloading timestamp                                                                            
No updates to your package list were found                                                       
Missing some cabal revision files, updating indices                                              
Selected mirror https://s3.amazonaws.com/hackage.fpcomplete.com/                                 
Downloading timestamp                                                                            
No updates to your package list were found                                                       
Did not find .cabal file for safe-exceptions-checked-0.1.0 with SHA of 2d07e15162937261823e35786206c8a218db8ae1 in tarball-based cache
Updating package index Hackage (mirrored at https://s3.amazonaws.com/hackage.fpcomplete.com/) ...The following package identifiers were not found in your indices: JuicyPixels-3.2.8.1, alternators-0.1.1.1, bench-1.0.3, cacophony-0.9.2, cmdargs-0.10.15, conduit-combinators-1.1.1, disposable-0.2.0.0, happstack-hsp-7.3.7.2, happstack-server-7.4.6.4, isotope-0.4.0.0, l10n-0.1.0.1, language-c-quote-0.11.7.3, machines-directory-0.2.1.0, matplotlib-0.4.1, microlens-0.4.8.0, microlens-ghc-0.4.8.0, microlens-platform-0.3.8.0, mime-mail-0.4.13.1, mixed-types-num-0.1.0.1, optparse-applicative-0.13.2.0, pipes-attoparsec-0.5.1.5, safe-exceptions-0.1.5.0, safecopy-0.9.3, search-algorithms-0.1.0, stm-extras-0.1.0.2, telegram-api-0.6.1.0, texmath-0.9.3, wai-middleware-auth-0.1.1.1, writer-cps-lens-0.1.0.1, writer-cps-morph-0.1.0.2, yesod-bin-1.5.2.1

(Note the very long last line)

Should I delete some stale cache files or something?

@sjakobi
Copy link
Member Author

sjakobi commented Mar 12, 2017

Should I delete some stale cache files or something?

I haven't seen these issues anymore since I executed rm -rf ~/.stack/indices but I'm still a bit unhappy about the unhelpful behavior of stack here. I think stack should either make a suggestion on what to do next (delete something?) or attempt to fix the issue itself.

Otherwise the user is just stuck with an unclear exception message and no obvious way to make the command succeed.

@sjakobi sjakobi reopened this Mar 12, 2017
@mgsloan
Copy link
Contributor

mgsloan commented Mar 14, 2017

Strange! Not sure what could lead to that, possibly a bug in hackage-security?

We might consider detecting when it isn't finding anything in the indices, and try deleting them in that case. (not sure that's happening here, but seems like it)

@sjakobi
Copy link
Member Author

sjakobi commented Mar 19, 2017

Strange! Not sure what could lead to that, possibly a bug in hackage-security?

It seems possible that I still had some funky index/cache data hanging around from haskell/hackage-server#573.

We might consider detecting when it isn't finding anything in the indices, and try deleting them in that case. (not sure that's happening here, but seems like it)

As we don't really understand what's going on we could ask users to make a bug report and append an archive of their ~/.stack/indices – that's probably what I should have done. Afterwards they could manually delete their ~/.stack/indices to fix their immediate problem.

@andrewufrank
Copy link

i just saw the same problem (probably after i deleted the lock in .stack/hackage, because i saw repeatedly the same messages "updating package index" with a hint to the lock). when i deleted the full .stack/indices it repopulated the index and now it seems to go ok.

@domenkozar
Copy link
Contributor

Seeing the same issue and removing indices does indeed fix the problem:

$ stack build --nix
There were multiple candidates for the Cabal entry "hlint.hs" (/Users/admin/domenkozar/cardano-sl/.stack-work/downloaded/XTTklt4ROs4T/hlint.hs), picking /Users/admin/domenkozar/cardano-sl/.stack-work/downloaded/XTTklt4ROs4T/tests/hlint.hs
Didn't see serokell-util-0.3 in your package indices.
Updating and trying again.
Selected mirror https://s3.amazonaws.com/hackage.fpcomplete.com/                                 
Downloading timestamp                                                                            
No updates to your package list were found                                                       
Updating package index Hackage (mirrored at https://s3.amazonaws.com/hackage.fpcomplete.com/) ...The following package identifiers were not found in your indices: serokell-util-0.3

@mgsloan
Copy link
Contributor

mgsloan commented Aug 7, 2017

A couple possibilities here:

  1. If the index gets updated, but stack gets killed before deleting the cache, then I think it will be stuck in a state where the cache won't update till the next index update.

  2. May be a caching issue in hackage-security

I'm thinking (1) seems plausible. Potential fix: After updating the package index reports no updates, check if the timestamp of the index is newer than the cache. If so, delete the cache. I've opened #3324 with this approach.

mgsloan added a commit that referenced this issue Aug 7, 2017
mgsloan added a commit that referenced this issue Aug 7, 2017
mgsloan added a commit that referenced this issue Aug 7, 2017
mgsloan added a commit that referenced this issue Aug 8, 2017
mgsloan added a commit that referenced this issue Aug 18, 2017
mgsloan added a commit that referenced this issue Aug 18, 2017
@mgsloan
Copy link
Contributor

mgsloan commented Aug 18, 2017

Hopefully this is fixed now. Closing. Probably good to open a new issue if it comes back.

@mgsloan mgsloan closed this as completed Aug 18, 2017
@dredozubov
Copy link
Contributor

dredozubov commented Sep 28, 2017

I'm seeing the similar problem just after pushing schematic-0.3.0.0 to hackage, not sure it's the same though:

Didn't see schematic-0.3.0.0 in your package indices.
Updating and trying again.
Selected mirror https://s3.amazonaws.com/hackage.fpcomplete.com/                        Downloading timestamp                                                                   No updates to your package list were found                                              Updating package index Hackage (mirrored at https://s3.amazonaws.com/hackage.fpcomplete.com/) ...The following package identifiers were not found in your indices: schematic-0.3.0.0
Perhaps you meant schema, schematic, schematic, schematic, schematic, schematic, schematic, schematic, schematic, or schematic?

@dredozubov
Copy link
Contributor

Update: removing ~/.stack/indices does indeed help. I also have a backup of indices folder in case someone will be willing to investigate the issue.

@mgsloan
Copy link
Contributor

mgsloan commented Sep 28, 2017

@dredozubov What version are you using? Note that the fix above is not in any released versions. The behavior you're seeing is consistent with what could happen before the fix.

@AndreasPK
Copy link
Contributor

This seems to be still an issue on 1.6.1

I just hit the issue (See commercialhaskell/lts-haskell#81) and deleting the indices solved it for me.

@dredozubov
Copy link
Contributor

dredozubov commented Dec 14, 2017 via email

@dnadales
Copy link

I'm seeing this error as well, but I don't know if it is due to trying to build with a very old version. Steps to reproduce:

git clone [email protected]:capitanbatata/argon.git
cd argon
stack --stack-yaml=stack-7.8.yaml build

Maybe I'm not using stack in the right way...

@erikd
Copy link

erikd commented Aug 1, 2018

I'm using stack version 1.7.1, with ltc-12.4 and getting:

The following package identifiers were not found in your indices: ghc-boot-th-8.4.3
Possible candidates: ghc-boot-th-8.4.1, ghc-boot-th-8.4.2.

I tried deleting ~/.stack/indicies but that did not help

@sjakobi
Copy link
Member Author

sjakobi commented Aug 1, 2018

@erikd: I'm wondering if the missing ghc-boot-th-8.4.3 is related to it being included in Stackage but not in Hackage:

image

@mihaimaruseac
Copy link
Contributor

That's interesting, afaik everything on Stackage has to be on Hackage too.

@crockeea
Copy link

@mihaimaruseac Your assumption seems to be false. I'm experiencing this issue today with resolver nightly-2018-11-14. My package is trying to use array (included with base).

On Stackage, array reports the following:

Version on this page: | 0.5.3.0
-- | --
LTS Haskell 12.18: | 0.5.2.0
Stackage Nightly 2018-11-14: | 0.5.3.0
Latest on Hackage: | 0.5.2.0

and on Hackage, indeed, the latest version is 0.5.2.0.

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

10 participants