Package cloud_firestore has no versions that match >=0.7.0 <0.8.0 derived from

518

Solution 1

Got it "fixed", although this is not really an answer.

Tried on a second computer, and it kept giving me the same issue.

Tried on the first computer, but at a different location, and flutter packages get works!

So...something in the first network location was blocking the repository?

Anyways, now it works as expected. Sorry, and thank you to everyone who gave me ideas to try!

Solution 2

There are docs that exist that say to include the following in your pubspec.yaml:

firebase_firestore: ^0.12.7+1

I believe those docs are wrong. It should be cloud_firestore, and the latest package versions can be found here:

https://firebaseopensource.com/projects/flutter/plugins/

Hope this helps someone.

Share:
518
TooManyEduardos
Author by

TooManyEduardos

Updated on December 05, 2022

Comments

  • TooManyEduardos
    TooManyEduardos over 1 year

    I'm trying to get the cloud_firestore package, which is required for this flutter tutorial: https://codelabs.developers.google.com/codelabs/flutter-firebase/#7

    when I run flutter packages get I only get back: Package cloud_firestore has no versions that match >=0.7.0 <0.8.0 derived from...

    The cloud_firestore package says on this website https://github.com/flutter/plugins/tree/master/packages/cloud_firestore that the latest version is 0.7.2 I tried that version as well, but I get the same error.

    I've also tried the dev, master and beta channels of flutter, without any success to get this package.

    And, here's my pubspec.yaml file:

    name: test_app
    description: Integrate firebase into flutter
    dependencies:
      flutter:
        sdk: flutter
      cupertino_icons: ^0.1.0
      cloud_firestore: ^0.7.0
    
    dev_dependencies:
      flutter_test:
        sdk: flutter
    
    flutter:
      uses-material-design: true
    

    Any suggestions on what could be going on? Thank you.

    • Tree
      Tree almost 6 years
      try running flutter clean in the console
    • Tree
      Tree almost 6 years
      also, I am not sure if you will need firebase_core
    • Tree
      Tree almost 6 years
      This is how I get the plugin, without the version cloud_firestore:
    • TooManyEduardos
      TooManyEduardos almost 6 years
      flutter clean -> Deleting 'build/'. and then flutter packages get -> ackage cloud_firestore has no versions that match >=0.7.2 <0.8.0 derived from:
    • Tree
      Tree almost 6 years
      try without the version number. Just :
    • Tree
      Tree almost 6 years
      I also sometimes got this errors, when switching from dev back to beta. I had to delete cache directory inside flutter sdk, and than run flutter upgrade again.
    • TooManyEduardos
      TooManyEduardos almost 6 years
      that seems to work! thank you (although I'm pretty sure it means that I'll keep getting the latest version, so it may not be "right" answer for a release project)
    • Tree
      Tree almost 6 years
      Also, there is flutter pub cache repair
    • Tree
      Tree almost 6 years
      good things to have in your quiver
    • TooManyEduardos
      TooManyEduardos almost 6 years
      actually...the app compiles (so it gets the package?) but it fails to run. lots of issues inside the cloud_firestore library
    • Tree
      Tree almost 6 years
  • TooManyEduardos
    TooManyEduardos almost 6 years
    with this suggestion, the app compiles, but fails to run
  • Mohith7548
    Mohith7548 almost 6 years
    Run "flutter clean" in the project directory terminal/cmd. Then try to run again. It should work now.
  • TooManyEduardos
    TooManyEduardos almost 6 years
    I mentioned this in a previous comment: flutter clean -> Deleting 'build/'. and then flutter packages get -> package cloud_firestore has no versions that match >=0.7.2 <0.8.0 derived from:
  • Eaweb
    Eaweb over 4 years
    This helped me. I wonder how one can suggest an edit to the doc that states firebase_firestore.