Home > Software design >  The imported package 'path' isn't a dependency of the importing package
The imported package 'path' isn't a dependency of the importing package

Time:10-03

I just upgraded my packages and now I started seeing a warning:

enter image description here

What is causing this?

CodePudding user response:

One or some of your packages (mostly likely the path_provider) had path as transitive dependency before you upgraded to their latest version, so you were able to import path directly in your code.

But the latest version no longer has dependency on path, so you will need to add this to your pubspec.yaml dependencies section like this:

dependencies:
  path: any
  • Related