capacitor-community / sqlite

Community plugin for native & electron SQLite databases
MIT License
426 stars 104 forks source link

out of memory since 1.9.0 #509

Closed k4ploc closed 3 months ago

k4ploc commented 3 months ago

I have tracked the issue in the sql.js repository because since version 1.9.0 I have had this problem, they just recently closed it but I continue with the problem.

https://github.com/sql-js/sql.js/issues/561#issuecomment-1849080965

Latest version : https://github.com/sql-js/sql.js/issues/561#issuecomment-1905270851

@jepiqueau in the last commit I saw that you did a rollback to version 1.8.0 there is no way to use the last one?

jepiqueau commented 3 months ago

@JuanLongines you said they fix the issue but you continue to have the issue so for the time being i stick to the 1.8.0 release. If you can share on github your app where you have still the issue using 1.9.0 i may have a look

k4ploc commented 3 months ago

@JuanLongines you said they fix the issue but you continue to have the issue so for the time being i stick to the 1.8.0 release. If you can share on github your app where you have still the issue using 1.9.0 i may have a look

I'm using the repository example, no additional code just updating sql.js version 1.10.2 https://github.com/jepiqueau/blog-tutorials-apps/tree/main/SQLite/Part-1/ionic7-angular-sqlite-app

jepiqueau commented 3 months ago

@JuanLongines Did it works with sql.js version 1.10.2

jepiqueau commented 3 months ago

@JuanLongines Fixed in release 5.5.2

folsze commented 3 months ago

Is it possible that this did not fix it?

I am still experiencing this error, even after updating to 5.5.2

I will update here if I was wrong, but if this happens to you too then maybe like this message.

k4ploc commented 3 months ago

@jepiqueau thank you !!, I have updated to the latest versions and its working now. @folsze did you copy the wasm file to the assets folder?

image

And no errors:

image

folsze commented 3 months ago

I was missing this step! Thanks a lot, especially for mentioning this again, that I have to copy the sql-wasm.wasm file.

Here is how to find the wasm file, if anyone forgot too: https://github.com/sql-js/sql.js/blob/master/README.md#usage

jepiqueau commented 3 months ago

@folsze you always have to copy the wasm file especially when the version of sql.js change that why it is better to have it in your scripts the build script should be amended to make the copy prior to build see example on my tutorial site