mvysny / solar-controller-client

Communicates with a solar controller (Renogy Rover) over RS232/USB and retrieves statistics
MIT License
2 stars 0 forks source link

sqlite3 sometimes fail with status 1280 #8

Closed mvysny closed 2 years ago

mvysny commented 2 years ago

1280/256=5 which means SQLITE_BUSY. This can happen when the sqlite database is read by Grafana and at the same time it's attempted to be written to by us.

PRAGMA busy_timeout = 1000; could help?

mvysny commented 2 years ago

Seems to be fixed by the PRAGMA statement. Closing as fixed.

mvysny commented 2 years ago

Similar issue can be seen in Grafana+sqlite plugin. Filed a bug: https://github.com/fr-ser/grafana-sqlite-datasource/issues/99