SQLITE integration having troubles on Desktop.

Database & APIs

Hello. It looks like the SQLite integration for FlutterFlow isn't working for Desktop app.If trying to run the app locally via FlutterFlow app, choosing "Windows" as device, this is the error that comes up on app startup:

[ERROR:flutter/runtime/dart_vm_initializer.cc(40)] Unhandled Exception: Bad state: databaseFactory not initializeddatabaseFactory is only initialized when using sqflite. 
When using sqflite_common_ffi You must call databaseFactory = databaseFactoryFfi; before using global openDatabase API
#0      databaseFactory.<anonymous closure>(package:sqflite_common/src/sqflite_database_factory.dart:29:7)
#1      databaseFactory (package:sqflite_common/src/sqflite_database_factory.dart:33:6)
#2      getDatabasesPath (package:sqflite_common/sqflite.dart:105:38)
#3      initializeDatabaseFromDbFile (package:opportunity_calc/backend/sqlite/init.dart:12:31)
#4      SQLiteManager.initialize (package:opportunity_calc/backend/sqlite/sqlite_manager.dart:24:23)
#5      main (package:opportunity_calc/main.dart:20:23)
#6      _runMain.<anonymous closure> (dart:ui/hooks.dart:301:23)
#7      delayEntrypointInvocation.<anonymous closure> (dart:isolate-patch/isolatepatch.dart:297:19)
#8      RawReceivePort.handleMessage (dart:isolate-patch/isolate_patch.dart:184:12)

I'm running a simple SQLite database with 2 tables and some columns.
What to do? The documentation on SQLite is really scarce, they included the essentials but nothing else.

What have you tried so far?

Made sure every column of the SQLite db was of Integer, Text, or Real type.

By searching online I found out it's likely an error caused by sqflite being incompatible with Windows and Mac, so I tried adding sqflite common ffi to the Pub Dependencies of the project, but it didn't solve anything (aside from a version error that I solved by downgrading to 2.3.4 instead of using the latest 2.3.5).

Did you check FlutterFlow's Documentation for this topic?
Yes
1