Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

success (and error) callbacks from database.close are never called #109

Closed
Typhlosaurus opened this issue Aug 8, 2014 · 5 comments
Closed

Comments

@Typhlosaurus
Copy link

in unit tests for our application we close, delete and then re-open the database before each test. As coded the actual database close is performed asynchronously but the confirmation callback is never called making database swapout unreliable.

Worse, in the android implementation this together with #112 mean that when a subsequent openDatabase() call is made for the same name, a new thread is started which can overlap with the old thread for the same database.

@nolanlawson
Copy link
Contributor

Would love a unit test and a fix for the Java code. :) Should be a one-liner for Android at least.

@Typhlosaurus
Copy link
Author

Ok - will do.

brodycj pushed a commit that referenced this issue Aug 20, 2014
…ng openDatabase()/db.close()/deleteDatabase() callbacks; double db.executeSql() callbacks; deleteDatabase() not reliable); small changes to deleteAndConfirmDeleted() helper function for existing test of sqlitePlugin.deleteDatabase()
brodycj pushed a commit that referenced this issue Aug 20, 2014
… db after delete (ref: #109/#110/#112); all but one test ok on iOS (www/SQLitePlugin.js regenerated)
@brodycj
Copy link
Contributor

brodycj commented Aug 21, 2014

After applying the changes to SQLitePlugin.coffee.md from the master branch of the @Typhlosaurus fork to the common-src branch of this project (and regenerating the Javascript), there is one failure on the iOS version in the close then re-open allows subsequent queries to run test. All of the other new tests from the master branch of the @Typhlosaurus fork are now passing on the iOS version. Some very nice work!

brodycj pushed a commit that referenced this issue Aug 21, 2014
brodycj pushed a commit that referenced this issue Aug 21, 2014
brodycj pushed a commit that referenced this issue Aug 21, 2014
…ented; close callbacks (#110) & deleteDatabase reliability (#112) on Android & iOS
@Typhlosaurus
Copy link
Author

Thanks.

On 21 August 2014 01:13, Chris Brody notifications@github.com wrote:

After applying the changes to SQLitePlugin.coffee.md from the master
branch of the @Typhlosaurus https://github.com/Typhlosaurus fork to the
common-src branch of this project (and regenerating the Javascript),
there is one failure on the iOS version in the close then re-open allows
subsequent queries to run test. All of the other new tests from the master
branch of the @Typhlosaurus https://github.com/Typhlosaurus fork are
now passing on the iOS version. Some very nice work!


Reply to this email directly or view it on GitHub
#109 (comment)
.

brodycj pushed a commit that referenced this issue Aug 22, 2014
… WP(8) open/close/delete issues (ref: #109/#110/#112); fix integer data binding (#123); credit for WP(8) fixes to mark.oppenheim@mnetics.co.uk
@brodycj
Copy link
Contributor

brodycj commented Aug 29, 2014

Now fixed inmaster (version 1.0.1)

@brodycj brodycj closed this as completed Aug 29, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants