Chrome Developer Tools, No Sensor in the console - google-chrome

I have a weird problem that I can't solve. I tried to reset the settings and reinstall Chrome but it didn't work. I'm testing a geolocated website so I want to use the sensor emulation to simulate different gps latitude and longitude. I followed the guides around the web but the tab don't show up. What's going on?
Sorry for the english but it's not my native language. I'm asking your help 'cause I'm going crazy.
You can see what I'm talking about in this screenshot:

The error Failed to load resource: net::ERR_BLOCKED_BY_CLIENT when associated with a URL that has "ads" in it strongly suggests that you have some kind of ad blocker installed in your browser.
On Google Chrome go to Settings > Extensions > AdBlock and uncheck Enable.

Related

How to get console logs on Chrome mobile without usb debug?

I once came across an SO answer that gave a Chrome URL to navigate to, that had a button to "enable" JS console logging. After enabling the logging, that tab would show the console logs of other Chrome tabs.
I know this answer seems like a duplicate, but I'm having a lot of trouble finding how to do that again. It was super convenient since it gave the console logs on any Chrome browser without needing a USB connected.
Any ideas? I know I came across it in an SO question about iOS debugging.
Found it! So, it's actually a Chrome on iOS only feature.
URL: chrome://inspect
That URL won't show anything on Chrome for Android, which tripped me up. But, on iOS it shows a "Start Logging" button.
Answer from: https://stackoverflow.com/a/55433616/2096769

Google Chrome developer tools works very slow

Sinсe Google Chrome was updated to 50.x version, it become impossible to work with DevTools. This issue reproduced mostly in "Network" tab. Every time when you click on "request" it takes about 30-40 sec. after that chrome can crash. Tried to delete all extensions, clear cache, and reinstall, but didn't help. Does anybody know how to fix this issue?
I'm running Chrome 50.0.2661.87 m
UPD: The problem may be occurs because of long headers. Try to close response and request headers.
I've been having similar issues for debugging in Chrome versions 50+ on Mac OS X 10.11.3. The only solution I've found so far is to keep the dev tools docked to the right and it seems to be as performant as before. Not the optimal solution, but it works in my case.
Finally, a solution has been found which helped me after such a long time and after so many failed attempts to fix it: Solution on Google Chrome Forums
Go to chrome://flags/#force-color-profile
Change it to sRGB
Since Google does not allow direct links to chrome:// you'll have to insert the colon by yourself, or enter the whole link manually into your toolbar.
My situation was similar, after struggling a while with extreme slow developer tools response I found out the problem was caused by a Chrome extension I had installed for knockoutJs.
So for people experiencing these issues, as part of the initial troubleshooting, try disabling chrome extensions.
I'm using the Version 61.0.3163.79 and I have the same issue that this post talks about.
With some searches I found out that the problem was in the user that I was using. What I tried was to enter int google chrome as guest and the devtools became faster again.
So what I did was:
Check out if debugging using the guest user is faster as it should be.
Logout from the account.
Clean all cache associated to google chrome.
Restart the PC (but i think closing the browser is enough)
Login again in your account.
I hope this could help other people with same problem.
[EDIT:]
I found out that after some time (weeks) the google chrome dev tools will get slower again. So I tried the following solution and it worked:
Open the dev tools
Go to the Sources tab.
Cleaned all watched variables, breakpoints, DOM breakpoint and Event Listeners breakpoint.
[SECOND EDIT:]
After some weeks, the issue came again. What I did was installing the google canary Version 64.0.3249.2 canary (64-bit) and my problems vanished.
For who's that doesn't know what is canary, please check this link.
Google is aware of the problem - https://bugs.chromium.org/p/chromium/issues/detail?id=624097
The problem seems to have vanished in v.53 - they are currently trying to figure out what fixed it. If possible, the fix will be merged back to v.52. But at least they are working on it.
In case others arrive here facing the same issue I had, try changing the Dev tools tab you're looking at to Elements.
I had the "Sources" tab open and Chrome was trying to load enormous assets for that tab, which created a multisecond delay between the console.log() events I created and the display of those logged messages.
Make devtools snappy again by deactivating all breakpoints:
Go to the Sources tab, show the debugger (may be hidden) and hit Deactivate breakpoints.
(Chrome v62.0 on Windows 10)
I've had the same time issue on 54.0.2840.99 m version of Google Chrome.
But switching to Chrome Canary worked !
Reduce size of resource being overridden
Only overriding files with less lines of code worked well for me. I landed here because I was overriding a file which had 35,000 + lines of Javascript.
Further, if your resource is a new one - i.e. it is not included in a script tag or link tag, you can override main html document and add the tag : <script src="/my-new-script.js"></script>. Add the file to your domain-root within the Overrides folder on Chrome:
overriding HTML
then overriding CUSTOM SCRIPT:
Good Luck...
I also face same issue.
I tried unchecked toggle screencast. Now it is working fine.
In my case, I had Local Overrides setup (https://developers.google.com/web/updates/2018/01/devtools#overrides) in Downloads folder which had a lot of files in it and that slowed down devtools.
Setting up overrides in its own seprate directory fixed the slowness.
I sped up Chrome again by doing the following:
Open DevTools -> select Elements tab ->
select nested Computed tab -> under Filter, make sure that Show all is unselected.
select nested Event Listeners tab -> make sure that Ancestors and Framework listeners are unselected.
For me, running Chrome Version 81.0.4044.138 (Official Build) (64-bit) on Ubuntu 18, the problem seems to be the mobile view. When I disable mobile view inspecting becomes really fast again. I think it is caused by touch emulation and other mobile stuff.
To have something similar to a mobile view I move the DevTools dock to the side and resize it until I get the width I need. It is not perfect, but it is useful most of the time.
Besides Chrome, Firefox is much faster when inspecting sites overall, though I didn't use FF because I'm used to specific things on Chrome. Moreover, most of the sites I work with do not trigger these issues on Chrome, in fact, it happens with only one site.
PD: the site that triggers the issue on Chrome Dev Tools has lots of CSS variables. Not sure if that is related.
UPDATE 1 WEEK ago
I was able to use Chrome without issues even in the mobile view by disabling the option "Show media queries"
Go to the network tool and change it without any restrictions. Sometimes this happens if you change mobile settings. Google chrome changes this setting to test mobile device on low internet connection and leaves it that way.

Why is my Chrome Extension grayed out?

Problem
A chrome extension I wrote is grayed out, and I can't figure out why.
Context
I wrote and submitted a Chrome Extension called Pull Favors to the Chrome webstore.
It uses the CSS order property to sort and group GitHub Pull-Requests in a logical way.
The other day I noticed that several of my extensions were grayed out, and 'blocked'--meaning they no longer work. One of these was Pull Favors.
According to this support article:
If you see a message saying "Extensions Disabled," it's because Chrome has turned off one or more of your extensions to keep your data safe while you're browsing the Internet. The extensions that Chrome turned off either didn't come from the Chrome Web Store or were installed without your permission."
My extension is published in the Chrome webstore and was certainly installed with my permission.
I've tried uninstalling and reinstalling to no avail.
I suspect there's something wrong with my extension (since a few other extensions seem to still work), but I can't figure out what it is or find anything about it on the internet.
What's going on?
Research
Chrome seems to have implemented a new policy in November 2013, which has caused some uproar in the community, which prevents Windows users from installing extensions from outside the web store.
I'm not sure why this is affecting me, as I'm an OS X user and, as I said, my extension is distributed through the webstore.
Add browser_action.default_icon in your manifest.json file
{
...
"browser_action": {
"default_icon": "icons/icon-32.png"
},
...
}
Before
After
In one of the last couple updates, they did something weird with the extensions that now makes all enabled extensions show up in either the toolbar or in the menu. In your case, the extension icon is grayed out because you don't even use a browser action or a page action, so it is just showing the icon. So it isn't disabled, just doesn't have an active state so is grayed out.
A quick search doesn't seem to turn up a blog post about it, but if you right click on the icon you can hide it in the menu.

Mystery flash of code displayed on page load

I have a screen full of code that displays for about half a second on loading some pages in chrome.
I managed to grab a screenshot of it.
I think this one is from a google search for the London tube map.
I have disabled chrome extensions and antivirus but it still appears.
Does anyone know what this is?
In this particular instance the code is generated by Bitdefender Traffic Light extension. If the antivirus is installed, the extension seems to be enabled without being displayed in Chrome's list of extensions.
Disabling the antivirus doesn't seem to disable the extension. But you can clearly see it is activated in a google search as each link has a specific icon next to it.
Other extensions might do a similar thing, but in the lower-left part of the screenshot, the code is:
fraud_link = "http://trafficlight.bitdefender.com/info?url={URL}&language=en_US";
Which makes it obvious this extention is causing the code to be displayed.

Google Analytics not loading in Chrome

When I try log in to Google Analytics in Chrome, the page doesn't load. Very odd. I just get what you see here:
I've never experienced it before recently, and it works on the same computer with Safari, but for about a week now it hasn't worked on Chrome. Any advice would be appreciated.
Likely an ad blocking plugin that had its ad database updated.
I know this question is old but I thought I'd add my answer.
For me it was adblocker on chrome. Click the hand in the red octagon next to your address bar. Go to options and click "show adds on web or domain", add the the domain https://www.google.com/analytics/ and that should fix it.
Clear your cache and disable any plugins that might be interfering.
Try in incognito or in private browsing as it will stop interference from extensions especially adblocking extensions
I tried on Incognito mode and different browsers but it is still not working. I also tried this on Chrome: Settings > Reset > Restore settings to their original defaults. I am still experiencing the same issue reported in this question. When I gave up trying everything on Windows, I tried from an iPhone (not the app, but visiting Google Analytics from a web browser on my iPhone 7 Plus in Chrome, no success. Then I moved to OS X Yosemite Version 10.10.5, and still the same, Google Analytics was not working. After spending several minutes trying, maybe for about an hour or more without success, it suddenly started working everywhere.
My conclusion is that most likely this was a bug in Google Analytics. I should have tested my Internet speed to see if the cause was poor Internet speed, but other pages were loading correctly. So I assume it was simply some kind of bug in Google Analytics.
EDIT: Today I am experiencing the same problem, and this is about 24 hours after the answer above that I posted yesterday. I went to http://www.speedtest.net/ to test my Internet speed, and these are the results:
Ping: 6ms
Download: 2.68 Mbps
Upload: 5.17 Mbps
Then I saw a pop-up telling me that an internal error had happened, and please close and open again the browser. This was definitely a bug in Google Analytics' service.
This is what I was seeing today, with Google Analytics never loading:
My problem was that google analytics wasn't collecting data from some users using browsers like Chrome and Firefox, and also when the users were active on my website, google's Real Time Reporting didn't work.
I found out that the users were using browser plugins like: AdBlock or disconnect.me wich were blocking the data collection.
I hope this helps someone because google brought me here while I was searching the internet for a solution to my problem.
And with some bits from here and some bits from there I managed to figure out what my problem was.
Thanks.
I had the same problem (Chrome, OSX), but I found out it had something to do with my extensions, as Google Analytics would properly load in Incognito Mode. In my case the extension Windscribe - Free VPN and Ad Blocker were preventing Analytics to load. I fixed it by whitelisting the domain.