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.

Issues with Twitter and Instagram built-in and custom rules + a feature suggestion

See original GitHub issue

Greetings

I’d like please to report a few issues I’ve noticed with Twitter and Instagram built-in and custom rules, and make a feature suggestion.

(using Chrome and Tampermonkey/Violentmonkey)


Regarding Twitter (new layout + “autoplay” enabled in https://twitter.com/settings/data) :

Here are two videos: (GIF/mp4) https://twitter.com/natfriedman/status/1232727363626029056 (blob) https://twitter.com/github/status/1191426884828950531

Inspecting the video nodes HTML, the former is mp4, the latter is blob:

GIF
<video preload="auto" playsinline="" aria-label="Embedded video" 
poster="https://pbs.twimg.com/tweet_video_thumb/ERuG9JhVUAEglNW.jpg" 
src="https://video.twimg.com/tweet_video/ERuG9JhVUAEglNW.mp4" type="video/mp4" 
style="width: 100%; height: 100%; position: absolute; background-color: black; top: 0%; left: 0%; transform: rotate(0deg) scale(1.005);"></video>
blob
<video preload="none" playsinline="" aria-label="Embedded video" 
poster="https://pbs.twimg.com/media/EIiwEVIVAAUWOqK.jpg" 
src="blob:https://twitter.com/59eda4ea-4178-43d4-b11a-09f26acf8203" 
style="width: 100%; height: 100%; position: absolute; background-color: black; top: 0%; left: 0%; transform: rotate(0deg) scale(1.005);"></video>

The rule from the repository (see below) doesn’t work when hovering on the mouse on each of the videos, although it seems it be still valid (although, the rule doesn’t work in the initial MPIV neither) . Could the rule below be modified to work for both videos?

{"d": "twitter.com",
 "e": "video",
 "s": "var bg = node.poster, url = /http[^\\\")]+/.exec(bg)[0];if (url.indexOf('.jpg') == -1){return url.replace('pbs', 'video').replace('_thumb', '').replace('.png', '.mp4');} else {return url.replace('pbs', 'video').replace('_thumb', '').replace('.jpg', '.mp4');}"
}

Regarding Instagram:


My feature suggestion (based on all the above):

to add a setting in “MPIV”, something like: “Display debug info for applied rule in console”, which, when enabled to display in console:

  • the currently applied rule (prettified, as in MPIV settings),
  • the actual values of its various properties, e.g. d, e, q, etc.
  • whether the applied rule rule is built-in or custom

This would help in quickly finding which rule is currently applied, and I believe that it would assist the user in improving/fixing the relevant rule.

 

Thank you!

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:39 (19 by maintainers)

github_iconTop GitHub Comments

1reaction
tophfcommented, Apr 6, 2021

Fixed in 72a6206a.

1reaction
tophfcommented, Apr 15, 2020

9ea318a1 Thanks.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Custom Twitter Feed Change Log - Smash Balloon
Fix: Fixed an issue with our integration with Burlaps GDPR consent plugin to apply changes to the feed only when consent is given....
Read more >
Instagram Debuts New Safety Settings For Teenagers - NPR
When kids under 16 join Instagram, their accounts will be made private automatically, as part of new safety settings for teens.
Read more >
Twitter Marketing in 2023: The Ultimate Guide - HubSpot Blog
Discover the ways marketing on Twitter can help you improve your brand awareness, boost conversions, and improve your sales.
Read more >
How to Use Twitter for Business - businessnewsdaily.com
This guide explains the basics of using Twitter for business and how to develop a social media marketing strategy that includes Twitter.
Read more >
26 Twitter Tips for Beginners You'll Wish You Knew Sooner
Whether you're a beginner or have a little experience under your belt, use these 26 Twitter tips that you'll wish you knew sooner....
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