cdsapi
cdsapi copied to clipboard
Replaced default python-requests user-agent with a custom ones
Default user-agent sent by cdsapi is inherited from it's dependency python-requests, which is python-requests/x.y.z
So it's not easy to know if the request came from official cdsapi or another Python code script that use python-requests under the hood.
Changing this can improve log analysis and QoS a bit (at least for 99% of users).
HTTP access log will now contains a user-agent field like the following:
… "cdsapi/0.5.1"
Hi @keul , Is this PR still relevant and useful? If so can you resolve the conflict and I will then review it and merge Thanks, Eddy
@EddyCMWF I think it can still be relevant. At the time I was trying to intercept users using the cdsapi, while right now there's not way to differentiate them from other people using "vanilla" Python requests.
If you think it can be useful I can fix conflicts
This should be merged asap
@gbiavati @EddyCMWF conflicts are fixed