Barebones SQLite support

SQLite library now has support for bundled SQLite databases.

Hi, I"m a newbie to use FUSE on my app. This Sqlite wrapper is really cool. I tried to include “include.unoproject”. But it shows this error. (I’m using OSX)

E0100: Package ‘…/…/…/…/Users/abc/Documents/Test/TestApp/fuse-sqlite/include.unoproj’ was not found

This is my project file. Do you know what I did wrong?

{ “RootNamespace”:"", “Packages”: [ “./fuse-sqlite/include.unoproj”, “Fuse.Animations”, “Fuse.BasicTheme”, “Fuse.Themes”, “Fuse.Controls”, “Fuse.Designer”, “Fuse.Drawing”, “Fuse.Drawing.Primitives”, “Fuse.Effects”, “Fuse.Elements”, “Fuse.Entities”, “Fuse.Gestures”, “Fuse.Navigation”, “Fuse.Scripting”, “Fuse.Shapes”, “Fuse.Triggers”, “Fuse.Reactive”, “Fuse.Android”, “Fuse.Desktop”, “Fuse.iOS”, “Fuse.UserEvents”, “FuseCore”, “Uno.Collections”, “Uno.Geometry” ], “Includes”: [ “*” ] }

It’s not supposed to be in the Packages, but in the Projects part of the unoproj. Also Fuse doesn’t play good if you put it in a subdirectory. Put it in a sibling directory instead, and refer to it as …/fuse-sqlite/include.unoproj.

"Projects": [
    "../fuse-sqlite/include.unoproj"
  ],

Thank you for your help. And there is another issue. It happeds ocassinaly; stucked on “Loading” page on preview. So I tried to preview on iOS with XCode. Here is error log.

Mar 17 15:01:32 APSEONOTE154 ids_simd[47075]: (Error) IDSSimulatorSupport: <IDSSimSupportLocalServer.m 68-[IDSSimSupportLocalServer setNetworkSimulation:enabled:completion:]_block_invoke:561> message send of data {
        ControlCmd = SetNetSimulationEnabledCmd;
        Enabled = 0;
        ServiceName = "com.apple.private.alloy.sockpuppet.classd";
    } failed with error Error Domain=com.apple.idssimualtorsupport.errors Code=2 "(null)" UserInfo={NSUnderlyingError=0x7fdd1270a770 {Error Domain=NSMachErrorDomain Code=268435459 "(ipc/send) invalid destination port"}}
Mar 17 15:01:32 APSEONOTE154 companionappd[47080]: (Error) WatchKit: <SPTransport.m 67-[SPTransport service:account:identifier:didSendWithSuccess:error:]_block_invoke:430> 67-[SPTransport service:account:identifier:didSendWithSuccess:error:]_block_invoke identifier (9E44F507-A0BB-4E32-8991-ADD1BB1C0656), serviceName ((null)), success: 0 error, domain: com.apple.identityservices.error, code: 23
Mar 17 15:01:32 APSEONOTE154 companionappd[47080]: (Error) WatchKit: <SPCompanionAppServer.m 75-[SPCompanionAppServer sendProtobuf:sender:timeOut:allowInsecureTransport:]_block_invoke:900> sendProtobuf failed, error : Error Domain=com.apple.identityservices.error Code=23 "Timed out" UserInfo={NSLocalizedDescription=Timed out, NSUnderlyingError=0x7f8bc8e13cf0 {Error Domain=com.apple.ids.idssenderrordomain Code=12 "(null)"}}
Mar 17 15:01:33 APSEONOTE154 companionappd[47080]: (Error) WatchKit: <SPTransport.m 67-[SPTransport service:account:identifier:didSendWithSuccess:error:]_block_invoke:430> 67-[SPTransport service:account:identifier:didSendWithSuccess:error:]_block_invoke identifier (ADCB10C7-904F-4A36-824B-2E444578E341), serviceName ((null)), success: 0 error, domain: com.apple.identityservices.error, code: 23
Mar 17 15:01:33 APSEONOTE154 companionappd[47080]: (Error) WatchKit: <SPCompanionAppServer.m __75-[SPCompanionAppServer sendProtobuf:sender:timeOut:allowInsecureTransport:]_block_invoke:900> sendProtobuf failed, error : Error Domain=com.apple.identityservices.error Code=23 "Timed out" UserInfo={NSLocalizedDescription=Timed out, NSUnderlyingError=0x7f8bc8e142e0 {Error Domain=com.apple.ids.idssenderrordomain Code=12 "(null)"}}
Mar 17 15:01:35 APSEONOTE154 sharingd[47085]: 15:01:35.399 : Failed to send SDURLSessionProxy startup message, error Error Domain=com.apple.identityservices.error Code=23 "Timed out" UserInfo={NSLocalizedDescription=Timed out, NSUnderlyingError=0x7f93a150caa0 {Error Domain=com.apple.ids.idssenderrordomain Code=12 "(null)"}}
Mar 17 15:02:34 APSEONOTE154 assertiond[47088]: assertion failed: 15D21 13C75: assertiond + 12188 [8CF1968D-3466-38B7-B225-3F6F5B64C552]: 0x1

Hi!

I followed the steps from GitReadme and run $ fusepm install [https://github.com/bolav/fuse-sqlite](https://github.com/bolav/fuse-sqlite) inside my project directory, put the <SQLite ux:Global="SQLite" /> in my MainView.ux file, and

var sqlite = require('SQLite');
var db = sqlite.open("file.sqlite");

in my MainView.js file and get this error

ERROR: 
    Name: System.ArgumentNullException: Argument cannot be null.
    Parameter name: key
      at System.ThrowHelper.ThrowArgumentNullException (ExceptionArgument argument) [0x00000] in <filename unknown>:0 
      at System.Collections.Generic.Dictionary2[System.String,Fuse.Scripting.ModuleResult].FindEntry (System.String key) [0x00000] in &lt;filename unknown&gt;:0 
      at System.Collections.Generic.Dictionary2[System.String,Fuse.Scripting.ModuleResult].ContainsKey (System.String key) [0x00000] in <filename unknown>:0 
      at Uno.Threading.ConcurrentDictionary2[System.String,Fuse.Scripting.ModuleResult].ContainsKey (System.String key) [0x00000] in &lt;filename unknown&gt;:0 
      at Fuse.Scripting.Module.Evaluate (Fuse.Scripting.Context c, System.String id) [0x00000] in &lt;filename unknown&gt;:0 
      at Fuse.Scripting.Module.EvaluateExports (Fuse.Scripting.Context c, System.String id) [0x00000] in &lt;filename unknown&gt;:0 
      at SQLite.Open (Fuse.Scripting.Context c, System.Object[] args) [0x00000] in &lt;filename unknown&gt;:0 
      at Fuse.Scripting.NativeFunction+NativeFunctionClosure.Callback (System.Object[] args) [0x00000] in &lt;filename unknown&gt;:0 
      at Fuse.Scripting.V8.Marshaller+CallbackWrapper.Call (Fuse.Scripting.V8.Simple.UniqueValueVector args) [0x00000] in &lt;filename unknown&gt;:0 
    Error message: Uncaught System.ArgumentNullException: Argument cannot be null.
    Parameter name: key
      at System.ThrowHelper.ThrowArgumentNullException (ExceptionArgument argument) [0x00000] in &lt;filename unknown&gt;:0 
      at System.Collections.Generic.Dictionary2[System.String,Fuse.Scripting.ModuleResult].FindEntry (System.String key) [0x00000] in <filename unknown>:0 
      at System.Collections.Generic.Dictionary2[System.String,Fuse.Scripting.ModuleResult].ContainsKey (System.String key) [0x00000] in &lt;filename unknown&gt;:0 
      at Uno.Threading.ConcurrentDictionary2[System.String,Fuse.Scripting.ModuleResult].ContainsKey (System.String key) [0x00000] in <filename unknown>:0 
      at Fuse.Scripting.Module.Evaluate (Fuse.Scripting.Context c, System.String id) [0x00000] in <filename unknown>:0 
      at Fuse.Scripting.Module.EvaluateExports (Fuse.Scripting.Context c, System.String id) [0x00000] in <filename unknown>:0 
      at SQLite.Open (Fuse.Scripting.Context c, System.Object[] args) [0x00000] in <filename unknown>:0 
      at Fuse.Scripting.NativeFunction+NativeFunctionClosure.Callback (System.Object[] args) [0x00000] in <filename unknown>:0 
      at Fuse.Scripting.V8.Marshaller+CallbackWrapper.Call (Fuse.Scripting.V8.Simple.UniqueValueVector args) [0x00000] in <filename unknown>:0 
    File name: /Users/kristofferhove/Desktop/OlavStedje/MainView.js
    Line number: 7
    Source line: var db = sqlite.open("file.sqlite");

Any idea what I am doing wrong?

Best regards!

Fuse made breaking changes to how you initialize an Uno object to a JavaScript object. The SQLite library is compatible with Fuse version 0.12.0 (build 6286) only.

Hi guys. Where can I find a tutorial for Fuse Sqlite? explaining step by step

does not exist the file https://www.dropbox.com/s/8hhummb1657lgv8/SQLiteImpl.CIL.dll?dl=0

how can I get this file ?