browserutils/sqlite3 never opens the -wal file, so every store kooky reads through it returns data as of that store's last checkpoint. Chrome, Firefox and Epiphany all call sqlite3.OpenFrom in their cookiestore.go, so a cookie a running browser wrote minutes ago can just be missing.
It showed up for me as a missing github.com user_session: the cookie was in a 754KB cookies.sqlite-wal while the main file still had logged_in and dotcom_user. The consuming tool reported no session for a browser that was signed in, and nothing tells that apart from actually being logged out.
Fix is a level down, in browserutils/sqlite3#1, which indexes the log and reads those pages from it. If that lands, kooky picks it up on a dependency bump with no code change here. I built kooky against it and the cookie shows up.
One thing to watch on kooky's side: sqlite3.OpenFrom finds the log by checking the reader for Name() string, which works because utils.OpenFile returns an *os.File. If that ever becomes a copy or a wrapper without Name(), the log is silently skipped and you're back to checkpoint-only reads.
browserutils/sqlite3never opens the-walfile, so every store kooky reads through it returns data as of that store's last checkpoint. Chrome, Firefox and Epiphany all callsqlite3.OpenFromin theircookiestore.go, so a cookie a running browser wrote minutes ago can just be missing.It showed up for me as a missing
github.comuser_session: the cookie was in a 754KBcookies.sqlite-walwhile the main file still hadlogged_inanddotcom_user. The consuming tool reported no session for a browser that was signed in, and nothing tells that apart from actually being logged out.Fix is a level down, in browserutils/sqlite3#1, which indexes the log and reads those pages from it. If that lands, kooky picks it up on a dependency bump with no code change here. I built kooky against it and the cookie shows up.
One thing to watch on kooky's side:
sqlite3.OpenFromfinds the log by checking the reader forName() string, which works becauseutils.OpenFilereturns an*os.File. If that ever becomes a copy or a wrapper withoutName(), the log is silently skipped and you're back to checkpoint-only reads.