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

Googlebot not flagged as bot #126

Open
JackCA opened this issue Dec 4, 2019 · 3 comments
Open

Googlebot not flagged as bot #126

JackCA opened this issue Dec 4, 2019 · 3 comments

Comments

@JackCA
Copy link

JackCA commented Dec 4, 2019

If you take the useragent string for the Googlebot smartphone bot:

Mozilla/5.0 (Linux; Android 6.0.1; Nexus 5X Build/MMB29P) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2272.96 Mobile Safari/537.36 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)

The above will be parsed as an android device without any botinfo.

If you change the priority of the rules array and put the Bot regexes as the first item, it works and you'll get bot as the name but you lose the OS and other information.

But I'm wondering if bot detection should actually just be attached to a bot attribute that is attached to all results? Then you would be able to get the OS (android) in this case but also know that it is a bot at the same time

@5punk
Copy link
Collaborator

5punk commented Dec 14, 2019

I think this is a good idea...

Some metadata about browsers would be handy with all the evolving IOT devices around

Thoughts @DamonOehlman ?

@DamonOehlman
Copy link
Owner

Yep, I completely agree that it's a good idea. I previously marked the bot flag as deprecated and that people should use the name to test for bot so I think it would be ok to release a new major version where bot returned a string that was useful (Googlebot in this particular case).

PR incoming.

@DamonOehlman
Copy link
Owner

@JackCA resolved in #127, however, I've got a few little tasks to do before I'll release a new major version that will implement support for this improved bot detection.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants