You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Probably you forgot (happened to me) to include the code below in the main.dart file :
Future main() async {
// To load the .env file contents into dotenv.
// NOTE: fileName defaults to .env and can be omitted in this case.
// Ensure that the filename corresponds to the path in step 1 and 2.
await dotenv.load(fileName: ".env");
//...runapp
}
E/flutter (13752): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: Instance of 'NotInitializedError'
E/flutter (13752): #0 DotEnv.env
package:flutter_dotenv/src/dotenv.dart:42
E/flutter (13752): #1 DotEnv.maybeGet
package:flutter_dotenv/src/dotenv.dart:58
E/flutter (13752): #2 DotEnv.get
package:flutter_dotenv/src/dotenv.dart:53
E/flutter (13752): #3 new ApiKeystore
package:user/.env/api_keystore.dart:23
E/flutter (13752): #4 main
package:user/main.dart:18
E/flutter (13752):
E/flutter (13752):
The text was updated successfully, but these errors were encountered: