question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error: attempt to write a readonly database (code 1032)

See original GitHub issue

Current behavior

Error: attempt to write a readonly database (code 1032)
  at f(node_modules/@react-native-community/async-storage/lib/AsyncStorage.js:413:25)
  at map(app:///[native code]:0:0)
  at apply(node_modules/@react-native-community/async-storage/lib/AsyncStorage.js:127:22)
  at __invokeCallback(node_modules/react-native/Libraries/BatchedBridge/MessageQueue.js:483:13)
  at fn(node_modules/react-native/Libraries/BatchedBridge/MessageQueue.js:135:12)
  at value(node_modules/react-native/Libraries/BatchedBridge/MessageQueue.js:384:9)
  at value(node_modules/react-native/Libraries/BatchedBridge/MessageQueue.js:134:18)
  at value(app:///[native code]:0:0)

We’re currently seeing a large spike of Android users receiving Error attempt to write a readonly database (code 1032).

Looks like our dependencies that rely on async-storage are throwing errors as well.

Expected behavior

No errors.

Environment

  • Async Storage version: 1.8.1
  • React-Native version: 0.61.4
  • Platform tested: Android

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:11 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
bscheideldyrtcommented, Mar 17, 2020

I wish we had a repro. We haven’t been able to get any of our devices in this state (either accidentally or attempting to force db states). We’re just seeing thousands of users who are now unable to write anything to async storage. I’m going to look at all of our dependencies to see if I can find any that are using the Core’s version of AsyncStorage.

1reaction
krizzucommented, Mar 17, 2020

I suspect this could be related to having both Community’s and Core’s AsyncStorage in a project. What Android are you seeing the issue on?

Read more comments on GitHub >

github_iconTop Results From Across the Web

SQLiteReadOnlyDatabaseExcep...
SQLiteReadOnlyDatabaseException : attempt to write a readonly database (code 1032) · The DB really is being closed/set to "readonly" in that 1ms ...
Read more >
attempt to write a readonly database (code 1032 ... - GitHub
I have users receiving this error: attempt to write a readonly database (code 1032 SQLITE_READONLY_DBMOVED[1032]) Some Googling and #178 ...
Read more >
attempt to write a readonly database (code 1032 ...
Coding example for the question I encounter Error [Error: attempt to write a readonly database (code 1032 SQLITE_READONLY_DBMOVED)] using expo-sqlite-React ...
Read more >
Fix the SQLite "attempt to write a readonly database" error
The database file's write bit for the web server user or group wasn't set. So, after setting it appropriately, the application would work....
Read more >
8 attempt to write a readonly database' after migrating
This article explains the 'General error: 8 attempt to write a readonly database' sometimes seen after migrating Tenable.sc to a new host.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found