I just restarted my computer and Chrome, but the timeline script and the fast abridged multiple/wrong answers script refuse to remember any modified settings as soon as I navigate to a different page.
How do I fix this?
I just restarted my computer and Chrome, but the timeline script and the fast abridged multiple/wrong answers script refuse to remember any modified settings as soon as I navigate to a different page.
How do I fix this?
Sounds like settings either arenāt getting saved to localstorage, or localstorage is being cleared somehow.
If you open Dev console (F12), and are on the āconsoleā tab, do you receive any errors when saving settings?
It says it saved, but before that it says āCannot read property āstartContainerā of nullā
Ā
Edit: Just realized youāre the person who made the abridged script, thanks so much for it! Itās actually maddening now, to see it say āDiD yOu kNoW tHeRE aRe oThER AnSwERs?ā instead of justā¦ showing me those answers, haha.
Sounding like a database issue.
Iām just assuming youāre using Chrome, as its what I use. Not entirely sure where in F12 this sits in IE/Edge/Firefox, but, do you find something similar:
Maybe @rfindley has some good insight. I seem to remember someone having an issue with a script recently that required clearing the db? I hate to jump to offering that advice if its not needed though.
Open Framework stores its settings in indexedDB. I havenāt seen Chrome have any problems with it yet, but thereās always a first time for everything.
If you look in the Application tab of the Dev Tools (by pressing F12), youāll see indexedDB in the left tab, and should be able to browse the āfilesā in the database. If thereās anything wrong (like, you canāt see any content in the database, or it reports an error), you could try deleting the database (thereās a button for that) and refresh the page.
Well, I deleted the database, but instead of a new one being created, it seems Iām just running without one at all now? (I did refresh the page)
I guess for the time being, maybe I can alter the values I want changed in the TamperMonkey interface.
Sometimes Chromeās database info in the Dev Tools doesnāt refresh properly (in my experience, anyway).
You can see whats in the cache by typing the following in the Javascript console:
wkof.file_cache.dir
then explore the result.
Your settings (for all wkof-based scripts) should be located at:
wkof.settings
And you can try manually loading/saving settings by:
wkof.Settings.load('timeline');
wkof.Settings.save('timeline');
I only describe all of this for troubleshooting purposes if you want to explore a bit.
Iām game for poking around a bit to solve this, I just donāt know how to interpret anything here
I took a look at the Abridged script to see if I could hard-code the settings I wanted, when I noticed a lot of error flags. There are even errors in WK Open Framework (which is #1 at the top of the load order):
Is thatā¦ normal?
After typing wkof.file_cache.dir
, you can click on the expand arrow to see the list of files (which includes settings) that wkof has stored in indexedDB.
The warnings youāre seeing in your screenshot are normal. TamperMonkey uses a code analysis tool to point out things that could be signs of an error, but a lot of the warnings are triggered by coding styles that differ from their assumed style. (like adding { } where itās not required).
Try turning off Timeline, refresh the page, and confirm that wkof.settings.timeline
doesnāt return any settings. Then enter wkof.Settings.load('timeline')
in the Javascript console, and check again if wkof.settings.timeline
returns some settings (youāll want to click on the expansion arrow on the returned results to see the actual settingsā¦ assuming it does return something). If it does, then loading is working, so next weād check saving by making a change to the settings.
Do you happen to be running the Rikaikun Chrome extension or anything? Not sure what that rikaicontent.js is.
@rfindley WKOF use it somewhere down the line? Not seeing it in my list of sources anywhere.
No, wkof only makes calls to WKās copy of jqueryā¦ no other 3rd-party stuff.
Iām having this exact same problem, whenever I change a setting in any user script I can see the changes applied, but whenever I refresh or open a new wanikani tab the settings are back to default.
After finding this thread I have gone through the suggestions made, have inspected for errors, tried deleting the databaseā¦but with no success.
In the Chrome console I can see the files associated with each script under IndexedDB / wkof.file_cache, and Iāve checked that after making a change in a particular setting, the corresponding entry is being updated.
So the problem seem to be that the scripts are not using those values when loading the website, although I donāt get any error in the Console related to that (just one about gravatarā¦)
@Kai_973 Where you able to solve this problem? Or does someone have an idea or what else could I try?
IIRC the problem went away after a day or two, but I donāt remember if it was because of anything I did, or if Tampermonkey or my browser just needed an update, or if restarting my computer did itā¦
I think if Iād solved it through something I did, I wouldāve mentioned it here. Sorry
No problem, thank you for replying As a workaround, Iāve found that since the changes I make are stored, I can just open the different Settings menus and āSaveā them each time I open the website for them to be applied.