Comments (2)
Is there some way the list can get wiped out? Some weird case viewing the blacklist, or some one in a million threading thing?
Absolutely. Both storage mechanisms for Chrome/WebExtensions are asynchronous by design. The sync storage (a.k.a. "cloud") sends the data via network with a corresponding roundtrip (latency will vary) while local storage (a.k.a. "save on local disk") asynchronously queues to reduce the blocking nature of the single JS engine thread that executes the extension. The integrity is kept by waiting on the callbacks before doing another access. However, due to multiple browser tabs, these callbacks/states have to be passed around as message to each tab, so every tab is up-to-date with the current blacklist state. And here is the part that might break. If an already outdated tab is broadcasting a message after the broadcast of a freshly updated tab was already processed, it will override the new with the old information. In theory, this should never happen because all broadcasts are queued by insertion, so the past can never outrun the future.
Going on, everytime you block/unblock something, the storage is touched and modified as a whole. There's no "just add or remove this single value" due to the way the blacklist is stored in order to "compress" the data. (I'm basically splitting up the list in several fragments to bypass storage restrictions such as "you can only have so many keys" imposed by the browser.) If something goes wrong here, I immediately try to restore the last known list (a temporary backup from memory) and warn the user via alert. I also gracefully handle the quota limits and apply the same logic. And what happens if a tab crashes in the middle of this operation? Nothing good, I suppose.
I've read your e-mail. The only explanation, I can come up with, is: The list was either damaged while writing or it was truncated while being fetched. So you end up with a smaller "working part" of the actual list. That doesn't really make sense in my book though, since JSON serialization/deserialization is either "everything or nothing", but maybe it was a partial recovery from memory (deserialized state) after a fault. I'm just guessing at this point as I cannot reproduce something like this at all.
Is the list backed up somewhere when using local storage so that I could get it back?
Your browsers helds the data. It's the same data that is fetched by the extension, so no, there's no additional backup available. Your only option is regularly exporting your list via extension (see management view) as .json file and keep it around to import back, in case your blacklist breaks. Sorry.
from unwanted-twitch.
K, thanks. I’ve got en export from March at least, so that will save some. Everyone since then gets a second chance on getting blocked!
from unwanted-twitch.
Related Issues (20)
- Hid channel when it shouldn't have HOT 1
- Filter by channel name (add regex to channel name filter) HOT 2
- Blacklist Filter for Tags is Not Case Sensitive HOT 7
- Add timestamp/ability to sort by when added to blacklist HOT 1
- Empty space where filtered user(s) are on "Following" page. HOT 1
- Seems like there is a limit to the block ammount. HOT 4
- Blocking Script types HOT 2
- Feature reqest: disable Twitch extensions HOT 1
- Firefox Extension appears to no longer be working HOT 16
- unwanted twitch doesn't not work HOT 1
- Symbols and characters ignored in lists (This issue is associated with #96) HOT 2
- **Kick.com** Support HOT 1
- Filter by number of viewers HOT 3
- Blacklisted titles does not make the stream in the sidebar disappear HOT 1
- Custom tag case sensitivity HOT 7
- The little x icon on the upper right of the thumbnail previews of different channels has disappeared HOT 1
- 'x' to add stream to block list has disappeared on the latest version of Firefox HOT 6
- A bug that ignore long note "ー" HOT 4
- Lists got cleared. HOT 4
- Darktheme. HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from unwanted-twitch.