Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kanji dictionary not showing #1080

Closed
vaer-k opened this issue Feb 15, 2023 · 26 comments · Fixed by #1088
Closed

Kanji dictionary not showing #1080

vaer-k opened this issue Feb 15, 2023 · 26 comments · Fixed by #1088

Comments

@vaer-k
Copy link

vaer-k commented Feb 15, 2023

Today I find that the extension is only showing vocabulary definitions. I can no longer use tab to switch to kanji definitions. I'm on Firefox 111.0b1 with tenten 1.13.5.
image

@birtles
Copy link
Member

birtles commented Feb 16, 2023

Hi! Sorry to hear the kanji dictionary is not working. That normally means that the downloaded dictionary data is not available and 10ten is using the data bundled with the add-on which only includes a snapshot of the word dictionary.

If the kanji tab used to work that suggests that either Firefox deleted the extension data (perhaps the disk got too full?) or had trouble accessing it (perhaps the disk permissions changed?) or there is some bug in 10ten where it decided the downloaded dictionary data is no longer available.

I wonder if you can try forcing the data to download using the following steps:

  1. Right-clicking the extension icon and choose "Manage extension"
  2. Go to the "Options" tab
  3. Go to the very bottom and click the "Check for updates" button

image

If there is some error, hopefully it will be displayed there.

@vaer-k
Copy link
Author

vaer-k commented Feb 16, 2023

Thank you for your advice. I appreciate your troubleshooting suggestions. The kanji tab did indeed used to work; it stopped working overnight. My disk has hundreds of gigabytes available, and as far as I can tell 10Ten has all required permissions (see image below.)

image

Although, in the options of the extension management section, I don't see the same dictionary data as you have displayed in your screenshot. See mine below.

image

@vaer-k
Copy link
Author

vaer-k commented Feb 16, 2023

I followed your suggestion to check for updates, and I also uninstalled the extension, restarted firefox, and reinstalled the extension, but neither of those approaches solved the issue.

@birtles
Copy link
Member

birtles commented Feb 17, 2023

Thanks for your patience and help in troubleshooting this. It's very odd. I'm not sure what could be happening.

If you enter about:debugging in the address bar, go to "This Firefox", then choose "Inspect" next to 10ten Japanese Reader, I wonder if you see any errors in the console there? Alternatively, maybe the Storage tab there, specifically the Indexed DB part, can tell us if the data is being stored or not.

I don't suppose you installed any other extensions recently? (Or perhaps they updated automatically? I've seen a few errors being reported that appear to be other extensions misbehaving.)

@vaer-k
Copy link
Author

vaer-k commented Feb 17, 2023

Of course, I'm happy to get any help at all. I don't see anything in Indexed DB, but there is something in Extension Storage:

Screenshot_20230217_093222
Screenshot_20230217_093211

I haven't installed any new extensions recently, but it is possible that one my other extensions updated. I use a dozen or so. Are there any particular kinds of egregious troublemakers?

@birtles
Copy link
Member

birtles commented Feb 18, 2023

It looks like it's not saving the data at all. I don't suppose you've enabled "Always-on private browsing" or "Never remember history" mode by chance? Firefox does not yet support using IndexedDB in private browsing mode and there are also settings in Firefox that causes this to apply to extensions too.

There are some details in #148.

In term of conflicting addons, I've seen a few error reports coming from a Kagi extension recently.

@CowFroggers
Copy link

RIP Kanji Dictionary :( I tried everything even removing and installing old version and nope I cant get kanji dictionary tab to show.

Capture

@CowFroggers
Copy link

CowFroggers commented Feb 19, 2023

this no luck, looking around may install the older firefox version

Capture

@vaer-k
Copy link
Author

vaer-k commented Feb 19, 2023

@birtles

I don't suppose you've enabled "Always-on private browsing" or "Never remember history" mode by chance?

Nope, don't use those.

In term of conflicting addons, I've seen a few error reports coming from a Kagi extension recently.

I don't use that one, and I can't identify any extensions I have installed that could present the same issue. 10ten is the only language-related extension I use. I tried disabling ublock, but that didn't seem to have any effect.

I wonder if it could be a Firefox update that is causing the issue.

@CowFroggers
Copy link

CowFroggers commented Feb 19, 2023

I tried enabling dis-enabling 'Always-on private browsing' and 'Never remember history' but it didn't make any difference for me.
I went and tested many builds firefox and found that 10ten works perfectly fine on build v108-0b5 no problems
the current latest build v111-0b2 that where it breaks, Firefox changed something but for now I'm just going to stick with build v108-0b5, (also v109 - v110 may work but tired of testing several builds for now)
it works good on v108-0b5 and not going to update until this mystery problem is found and dealt with, btw thank you for this great plug in you put together, it the Best.
(Using the Firefox Developer Build v108-0b5 in win8.1 enterprise if helps to know the environment I'm using.)

@birtles
Copy link
Member

birtles commented Feb 19, 2023

Hmm, that's really odd. I'm using 111 at work and 112 at home without problems. Both systems are Windows 11.

I see that @CowFroggers is on Win 8.1 Enterprise. @vaer-k what OS are you on?

@CowFroggers thanks for checking all those builds. Just to confirm, did you try v111 with a new profile?

@CowFroggers
Copy link

CowFroggers commented Feb 20, 2023

Now I'm currently using Firefox Developer Build 110.0b1 (64-bit) with the plugin and everything Works Perfectly

When I try Firefox Developer v111.0b3 that when the 10ten no longer does kanji dictionary, I tried both updating the software and with a fresh install and with the data cleared or with the previous data restored it all the same for me with v111 Firefox Developer Edition, I have not tested this with regular Firefox only the Developer Edition.

Untitled-1

@birtles
Copy link
Member

birtles commented Feb 20, 2023

Wow, that's really helpful. I tracked down the changes between beta 1 and beta 3 but I don't see anything obvious there:

https://hg.mozilla.org/releases/mozilla-beta/pushloghtml?fromchange=FIREFOX_111_0b1_RELEASE&tochange=FIREFOX_111_0b3_RELEASE

Also, @vaer-k originally reported seeing the problem on 111.0b1.

I'll poke some people on the Firefox addons team but first I'd like to check if @vaer-k is on Windows 8 and/or using Developer Edition so we can narrow down the parameters.

@birtles
Copy link
Member

birtles commented Feb 20, 2023

Actually, never mind. I managed to reproduce this on my home computer so I can try to debug it there tomorrow. Thanks for reporting it!

@birtles
Copy link
Member

birtles commented Feb 20, 2023

It looks like this is coming from bug 1247687 which adds support to worker modules in v111. We're loading the background script as a module (not sure why) and that appears to be broken.

It's an easy fix for Firefox (just drop the { type: 'module' } part) but I need to check it doesn't break other browsers.

@birtles
Copy link
Member

birtles commented Feb 21, 2023

I still haven't quite worked out exactly what is going on, but I think Firefox 111 introduced support for worker modules but then put it behind a flag for non-Nightly versions (source).

So on Nightly (currently 112) they will work since the flag is enabled there. In release, that feature hasn't arrived so the { type: 'module' } annotation will be ignored, but in 111 the type is parsed, but because the pref is disabled, it will throw (see https://hg.mozilla.org/mozilla-central/rev/1f5f65f28752).

Hikibiki appears to be unaffected, despite using workers with { type: 'module' } because I believe the webpack setup is different there, causing the { type: 'module' } annotation to be transpiled to { type: void 0 }.

Which is all to say, I need to fix the extension but in the short-term, you might be able to get it to work by going to about:config and toggling dom.workers.modules.enabled to true (and possibly restarting the browser after that or perhaps simply disabling and re-enabling 10ten).

@vaer-k
Copy link
Author

vaer-k commented Feb 21, 2023

Thank you @birtles. Your communication here is so appreciated. At this point I know you no longer need to know, but for the record I'm Firefox dev and Windows 11.

@birtles
Copy link
Member

birtles commented Feb 22, 2023

Not at all! Thank you @vaer-k and @CowFroggers! Thanks to your help, we identified this issue while it still only affects Firefox beta so that we can fix it before it affects Firefox release too (on March 14).

@VarNepvius
Copy link

[…] you might be able to get it to work by going to about:config and toggling dom.workers.modules.enabled to true (and possibly restarting the browser after that or perhaps simply disabling and re-enabling 10ten).

I can confirm that enabling the about:config-setting and then disabling and re-enabling 10ten in about:addons makes the Kanji tabs work again.

I am on 111.0b2 Dev Edition by the way

@birtles
Copy link
Member

birtles commented Feb 22, 2023

Thank you!

birtles added a commit that referenced this issue Feb 23, 2023
This was causing Firefox beta 111 to break since it starts parsing this
annotation and then failing when it is set.

Fixes #1080.
birtles added a commit that referenced this issue Feb 23, 2023
This was causing Firefox beta 111 to break since it starts parsing this
annotation and then failing when it is set.

Fixes #1080.
@birtles
Copy link
Member

birtles commented Feb 23, 2023

I've published 1.13.6 which should fix this. If anyone can confirm that would be great.

@VarNepvius
Copy link

VarNepvius commented Feb 23, 2023

I've published 1.13.6 which should fix this. If anyone can confirm that would be great.

It does for me.

I double checked, that the above about:config setting is off (default) and briefly switched to 1.13.5 to confirm, that it really is the upgrade, that makes the difference.

Thanks @birtles !

@birtles
Copy link
Member

birtles commented Feb 23, 2023

Thank you @VarNepvius!

@vaer-k
Copy link
Author

vaer-k commented Feb 24, 2023

@birtles Works for me. What great and fast work! Thank you

@birtles
Copy link
Member

birtles commented Feb 25, 2023

Thanks @vaer-k!

@CowFroggers
Copy link

CowFroggers commented Feb 26, 2023

Thank you very much Vaer-k, Birtles and everyone else involved awesome work !!!!!!!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants