1. API Information

    The TurkerView API page has instructions as well as contact information for support in getting set up with our new API infrastructure.

    You can also email us directly at hello@turkerview.com if you run into any problems!

    Dismiss Notice

Chrome 57+ Throttling

Discussion in 'Help & Guides' started by Kadauchi, Mar 15, 2017.

  1. Kadauchi

    Kadauchi Survey Slinger

    Messages:
    3,931
    Ratings:
    +7,369
    ********************* Update Nov 2018 *********************
    *************************************************************************

    Chrome 57 has been released recently. This version introduces background tab throttling to help improve performance. This is important to know about for workers because many important scripts you use can be affected by this.

    Throttling of background tabs already existed, slowing them down to only be able to run once every second, but now they are going to be limited to an average of 1% CPU usage.

    Affected scripts

    Affected browsers
    • Chrome
    • Chrome Canary
    • Chromium
    • Opera (?)
    • Vivaldi (?)
    (?) denotes unconfirmed, but they are based off of chromium so they should be when their bases get updated to Chromium 57+


    How to opt-out

    Windows:
    1. Right click the shortcut you use to launch chrome and select properties.
    2. Add --disable-background-timer-throttling to the end of the target line, there needs to be a space separating it as pictured below.
    3. You will have to exit out of Chrome completely for this to take affect and always use the edited shortcut to launch chrome or the flag will not run.

    [​IMG]

    Mac:

    Enter this into the terminal
    Code:
    /Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome   --disable-background-timer-throttling
    
    You will have to do this everytime you launch Chrome or you can follow these instructions: https://turkerhub.com/posts/106128/

    Both:
    You can verify that the flag is enabled by going to chrome://version and seeing --disable-background-timer-throttling under "Command Line".

    How to know if a tab can to be throttled

    Any background tab that is not playing audio or does not have a WebSocket/WebRTC will be throttled unless you opt-out.

    HIT Finder would not be throttled since it is in the foreground
    [​IMG]

    HIT Finder would be throttled since it is in the background.
    [​IMG]

    Having the scripts in their own window will prevent them from being throttled as long as they aren't minimized. You can have other windows covering them, just do not minimize them to the system tray.
     
    • Useful / Informative Useful / Informative x 18
    • Love Love x 4
    • Like Like x 1
    Last edited: Nov 27, 2018
  2. Hazmat

    Hazmat Survey Slinger

    Messages:
    2,151
    Ratings:
    +3,842
  3. jessers

    jessers Survey Slinger

    Messages:
    10,393
    Gender:
    Female
    Ratings:
    +29,055
    It seems like the way to do this on Mac is by pasting
    Code:
    /Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome   --disable-background-timer-throttling
    into Terminal.

    I think. It at least didn't break anything when I did it. So. Um. Yeah.

    I also don't know if you have to do this every time you launch Chrome. So. Um. Yeah.

    :oops: Hopefully someone smarter than I will figure it out. @RicanGuy86?


    Edit:

    Or is this also it?

    chrome://flags/#expensive-background-timer-throttling
    [​IMG]
     
    • Useful / Informative Useful / Informative x 3
    • Love Love x 1
    Last edited: Mar 15, 2017
  4. Kadauchi

    Kadauchi Survey Slinger

    Messages:
    3,931
    Ratings:
    +7,369
    If that gets confirmed to be working I'll add it to the main post for everyone else. That flag doesn't do anything, first thing I tested. Q2 2017 there should be an update that allows us to opt-out.
     
    • Like Like x 1
    • Useful / Informative Useful / Informative x 1
  5. RicanGuy86

    RicanGuy86 Survey Slinger

    Messages:
    3,761
    Ratings:
    +7,333
    The solution @jessers provided works.

    Verified by using the Chrome command chrome://verison.

    No flag:
    [​IMG]

    Flag enabled:
    [​IMG]

    The only thing is, Mac users will have to open Chrome using Terminal and specify the flag every single time they'd like to opt-out.
     
    • Useful / Informative Useful / Informative x 2
  6. Kadauchi

    Kadauchi Survey Slinger

    Messages:
    3,931
    Ratings:
    +7,369
    Thanks added the info to the orig post.
     
    • Like Like x 1
  7. RicanGuy86

    RicanGuy86 Survey Slinger

    Messages:
    3,761
    Ratings:
    +7,333
    Mac users can use a simple AppleScript to create an app that opens Chrome with the flag enabled.

    This is how:

    1. Navigate to Script Editor (Utilities > Script Editor)

    2. Copy this bit into Script Editor:
    Code:
    tell application "Terminal"
        do script "/Applications/Google\\ Chrome.app/Contents/MacOS/Google\\ Chrome   --disable-background-timer-throttling"
    end tell
    3. Save the AppleScript as an application:

    [​IMG]

    This creates an app that a Mac user can double-click and open Chrome with the flag enabled.
     
    • Useful / Informative Useful / Informative x 3
    • Love Love x 2
    Last edited: Mar 16, 2017
  8. turks24

    turks24 Survey Slinger

    Messages:
    6,218
    Gender:
    Male
    Ratings:
    +13,100
    Do I need to leave there terminal window open while using Chrome?
     
    • Like Like x 1
  9. RicanGuy86

    RicanGuy86 Survey Slinger

    Messages:
    3,761
    Ratings:
    +7,333
    Yep. If you close it, you close Chrome.
     
    • Useful / Informative Useful / Informative x 1
  10. HardWorkingTurker

    HardWorkingTurker Survey Slinger

    Messages:
    4,682
    Ratings:
    +3,797
    UPDATE:
    You can now go to chrome://flags/
    search for Throttling
    At Throttle expensive background timers
    click "Disable"
    restart Chrome for it to work.
     
    • Love Love x 1
    • Useful / Informative Useful / Informative x 1