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

[BUG] Akita not detecting monetization in Firefox #120

Closed
sharon-wang opened this issue Feb 16, 2021 · 1 comment · Fixed by #127
Closed

[BUG] Akita not detecting monetization in Firefox #120

sharon-wang opened this issue Feb 16, 2021 · 1 comment · Fixed by #127
Assignees
Labels
browser compatibility Relating to compatibility across browsers bug Something isn't working investigation needed Need to look into this more to understand what's wrong

Comments

@sharon-wang
Copy link
Member

sharon-wang commented Feb 16, 2021

Describe the bug
In Firefox only, Akita seems to not be detecting Web-Monetized sites, as the browser icon does not change to reflect that a site is monetized and top site data is not being stored.

To Reproduce
Steps to reproduce the behavior:

  1. Install Akita in Firefox
  2. Go to a Web-Monetized site
  3. Observe that the Akita icon does not change and no top site data is shown

Expected behavior
The Akita icon should change to the monetized state and top site data should show up in the extension popup after visiting a Web-Monetized site.

Screenshots
image

Desktop:

  • OS: Mac
  • Browser and Version: Firefox 83 and 85, possibly other versions too

Additional context
Monetization detection was working on Firefox at one point, but we haven't been diligent about testing on Firefox. We haven't tested on Firefox for the last couple of Chrome releases, so the problem could be from a ways back.

We started injecting a script onto the page to help us manage listening to monetization events. It seems like this could be where things are going wrong for Firefox, but more investigation is needed.

@sharon-wang sharon-wang added bug Something isn't working browser compatibility Relating to compatibility across browsers investigation needed Need to look into this more to understand what's wrong labels Feb 16, 2021
@vezwork
Copy link
Member

vezwork commented Feb 16, 2021

There is a workaround if it is in-fact the case that the code injection is not working as expected. We can listen to monetization events on the window object of the page in the content script instead of injecting a script, which is necessary to listen to monetization events on the document.monetization object. Even though it's simpler to listen to events on window and it does the same thing as listening on the document.monetization object in practice, we don't currently do it because it is not part of the Web Monetization spec so it could stop working at any time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
browser compatibility Relating to compatibility across browsers bug Something isn't working investigation needed Need to look into this more to understand what's wrong
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants