question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

inline tipping doesn't work under Twitter

See original GitHub issue

Description

Inline tipping has stopped working under Twitter. When pressing the inline BAT button, you’ll get the following errors in the browser console:

brave_rewards_panel_content_twitter.bundle.js:1 Failed to fetch tweet details for 1204589420617371649: Unexpected end of JSON input
(anonymous) @ brave_rewards_panel_content_twitter.bundle.js:1
Promise.catch (async)
l @ brave_rewards_panel_content_twitter.bundle.js:1
s.onclick @ brave_rewards_panel_content_twitter.bundle.js:1

brave_rewards_panel_content_twitter.bundle.js:1 Failed to fetch tweet metadata for [object HTMLDivElement]: SyntaxError: Unexpected end of JSON input
    at a (brave_rewards_panel_content_twitter.bundle.js:1)
(anonymous) @ brave_rewards_panel_content_twitter.bundle.js:1
Promise.catch (async)
s.onclick @ brave_rewards_panel_content_twitter.bundle.js:1

brave_rewards_panel_content_twitter.bundle.js:1 Cross-Origin Read Blocking (CORB) blocked cross-origin response https://api.twitter.com/1.1/statuses/show.json?id=1204589420617371649 with MIME type application/json. See https://www.chromestatus.com/feature/5629709824032768 for more details.
a @ brave_rewards_panel_content_twitter.bundle.js:1
async function (async)
a @ brave_rewards_panel_content_twitter.bundle.js:1
(anonymous) @ brave_rewards_panel_content_twitter.bundle.js:1
l @ brave_rewards_panel_content_twitter.bundle.js:1
s.onclick @ brave_rewards_panel_content_twitter.bundle.js:1

You’ll get the following errors in the terminal:

[79025:775:1210/223655.310171:INFO:CONSOLE(1)] "Failed to fetch tweet details for 1204604280180789248: Unexpected end of JSON input", source: chrome-extension://jidkidbbcafjabdphckchenhfomhnfma/out/brave_rewards_panel_content_twitter.bundle.js (1)

Seems like something was introduced in C79 that’s causing the issue. Errors in the browser console are mentioning a CORS issue.

Steps to Reproduce

  1. install & launch 1.1.20 CR: 79.0.3945.74
  2. enable Rewards and login into https://twitter.com/
  3. attempt to tip users/tweets via inline tipping

Actual result:

Clicking on the BAT icon via inline won’t do anything and will produce the above errors mentioned above via the browser console and the terminal.

Expected result:

Clicking on the BAT icon via inline on Twitter should display the tipping banner.

Reproduces how often:

100% reproducible when using the above STR.

Brave version (brave://version info)

Brave 1.1.20 Chromium: 79.0.3945.74 (Official Build) (64-bit)
Revision 99b6d241cf84f7fa7434ae8a59f9e74eb1464280-refs/branch-heads/3945@{#888}
OS macOS Version 10.15.1 (Build 19B88)

Version/Channel Information:

  • Can you reproduce this issue with the current release? Reproducible
  • Can you reproduce this issue with the beta channel? Reproducible
  • Can you reproduce this issue with the dev channel? Reproducible
  • Can you reproduce this issue with the nightly channel? Reproducible

Other Additional Information:

  • Does the issue resolve itself when disabling Brave Shields? No, still reproducible
  • Does the issue resolve itself when disabling Brave Rewards? N/A
  • Is the issue reproducible on the latest version of Chrome? N/A

Miscellaneous Information:

CCing @rebron @bsclifton @brave/legacy_qa @NejcZdovc

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
btlechowskicommented, Dec 13, 2019

Verification passed on

Brave 1.1.21 Chromium: 79.0.3945.79 (Official Build) (64-bit)
Revision 29f75ce3f42b007bd80361b0dfcfee3a13ff90b8-refs/branch-heads/3945@{#916}
OS Windows 7 Service Pack 1 (Build 7601.24530)

Verified test plan from the description and https://github.com/brave/brave-core/pull/4215. Verified that I was able to tip the publisher. Verified that the tip was visible under Tips on brave://rewards

Verification passed on

Brave 1.1.21 Chromium: 79.0.3945.79 (Official Build) (64-bit)
Revision 29f75ce3f42b007bd80361b0dfcfee3a13ff90b8-refs/branch-heads/3945@{#916}
OS Ubuntu 18.04 LTS

Verified test plan from the description and https://github.com/brave/brave-core/pull/4215. Verified that I was able to tip the publisher. Verified that the tip was visible under Tips on brave://rewards

Verified passed with

Brave 1.1.21 Chromium: 79.0.3945.79 (Official Build) (64-bit)
Revision 29f75ce3f42b007bd80361b0dfcfee3a13ff90b8-refs/branch-heads/3945@{#916}
OS macOS Version 10.13.6 (Build 17G5019)
  • Verified test plan from https://github.com/brave/brave-core/pull/4215

  • Verified able to see custom banner data when tipping from panel Screen Shot 2019-12-13 at 9 22 53 AM

  • Verified normal banner displayed as well: Screen Shot 2019-12-13 at 9 23 25 AM

  • Verified able to tip Twitter publishers from panel and tips displayed in Tips panel on brave://rewards Screen Shot 2019-12-13 at 9 24 03 AM

  • Verified in-line tipping for Twitter, Reddit, and GH showed the expected banners (encountered https://github.com/brave/brave-browser/issues/5562 for in-line tipping on GH) and am able to tip on each of these sites: Screen Shot 2019-12-13 at 9 39 00 AM Screen Shot 2019-12-13 at 9 42 59 AM Screen Shot 2019-12-13 at 9 45 48 AM

Verification PASSED on macOS 10.15.1 x64 using the following build:

Brave 1.1.21 Chromium: 79.0.3945.79 (Official Build) (64-bit)
Revision 29f75ce3f42b007bd80361b0dfcfee3a13ff90b8-refs/branch-heads/3945@{#916}
OS macOS Version 10.15.1 (Build 19B88)

Note: Used Production instead of Staging

  • Verified test plan from the description and https://github.com/brave/brave-core/pull/4215.
  • Verified that I was able to tip the publisher.
  • Verified that the tip was visible under Tips on brave://rewards
  • also checked GH & Reddit re: inline tipping
1reaction
bscliftoncommented, Dec 12, 2019
Read more comments on GitHub >

github_iconTop Results From Across the Web

About Tips and tipping - Twitter Help Center
You can tip to show support, show appreciation, help out or reward anyone you want – from emerging creators and journalists to Twitter...
Read more >
Custom Audiences - Twitter for Business
If your Custom Audience is under 100 Twitter users, it will display as "Audience too small" and will not be available for selection....
Read more >
Our range of enforcement options for violations | Twitter Help
Learn about various levels at which we may take action, what happens, and how you can appeal an account suspension.
Read more >
List Custom Audiences - Twitter for Business
If your List Custom Audience is under 100 Twitter users, it will display as "Audience too small" and will not be available for...
Read more >
Working with Web Intents - Twitter Developers
Web Intents provide flows for working with Tweets & Twitter Users: Tweet, Reply, Retweet, ... If a viewer does not have a Twitter...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found