-
Notifications
You must be signed in to change notification settings - Fork 49
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
Feature/add analytics #387
Conversation
e18ab2b
to
5f2b3a3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know it is not ready yet, but this is the correct header name! ;)
137aea6
to
96cbb42
Compare
96cbb42
to
eb54b77
Compare
eb54b77
to
72daf28
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@alallema the user agent implemented will be used to inform the scrapped pages that they are going to be scraped by Meilisearch.
But the one that we need is this one: meilisearch/integration-guides#150 which is the user-agent we send to meilisearch.
So I assume you had to pass it from Meilisearch Python.
044c385
to
fc89a6e
Compare
771: Adding a header parameters to the client constructor r=alallema a=alallema To enable and facilitate the integration of a user-agent into all SDKs. [see related issue](meilisearch/integration-guides#150) and specifically for [the docs-scraper integration](meilisearch/docs-scraper#387) a new parameter client_agent is now available in the client constructor. Co-authored-by: alallema <[email protected]> Co-authored-by: Amélie <[email protected]> Co-authored-by: Paul Sanders <[email protected]>
86351c2
to
e5d627c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good work ✨
) | ||
|
||
# Then | ||
assert actual.meilisearch_client.http.headers['User-Agent'] == f"Meilisearch Python (v0.27.0);Meilisearch DocsScraper (v{__version__})" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The fact that all these headers are not separated by a white space makes matching harder on our analytics tools no?
It might not be a prefix search strategy though!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a good question, I have no idea, but I think @brunoocasali will be better able to answer, as these entries will be used through Amplitude.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nope @bidoubiwa it is correct like this, they use the ;
semicolon as the separator.
More about it here in this comment: meilisearch/integration-guides#150 (comment)
e5d627c
to
b7b1931
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 🔥🔥
Following this central issue meilisearch/integration-guides#150
This repo now add a user-agent in the header of docs-scraper