When I want to start the Flutter project on vscode, it gives me such an error and I searched everywhere and did not find a solution:
flutter_application_6] flutter create --template app --overwrite .
Waiting for another flutter command to release the startup lock.
Creating project …
Resolving dependencies…
Because flutter_application_6 depends on flutter_lints any which doesn’t exist (authorization failed), version solving failed.
Insufficient permissions to the resource at the https://pub.dev package repository.
You can modify credentials using:
dart pub token add pub.dev
Failed to update packages.
exit code 69
I must say that Flutter and Dart versions are updated in their latest versions
and result flutter run apear this error:
flutter run
Connected devices:
Windows (desktop) • windows • windows-x64 • Microsoft Windows [Version 10.0.19045.5440]
Chrome (web) • chrome • web-javascript • Google Chrome 132.0.6834.160
Edge (web) • edge • web-javascript • Microsoft Edge 132.0.2957.140
[1]: Windows (windows)
[2]: Chrome (chrome)
[3]: Edge (edge)
Please choose one (or “q” to quit): 2
Resolving dependencies… (1.1s)
Because flutter_application_6 depends on flutter_lints any which doesn’t exist (authorization
failed), version solving failed.
Insufficient permissions to the resource at the https://pub.dev package repository.
You can modify credentials using:
Failed to update packages.
pubspec.yaml:
name: flutter_application_6
description: “A new Flutter project.”
publish_to: ‘none’
version: 1.0.0+1
environment:
sdk: ^3.6.0
dependencies:
flutter:
sdk: flutter
cupertino_icons: ^1.0.8
dev_dependencies:
flutter_test:
sdk: flutter
flutter_lints: ^5.0.0
flutter:
uses-material-design: true