Skip to content

Fix user-agent used by buf curl#2475

Merged
jhump merged 1 commit intomainfrom
jh/bufcurl-user-agent
Oct 4, 2023
Merged

Fix user-agent used by buf curl#2475
jhump merged 1 commit intomainfrom
jh/bufcurl-user-agent

Conversation

@jhump
Copy link
Member

@jhump jhump commented Oct 4, 2023

According to this page, it looks like I should add extensions to the user agent to the end, not the beginning. So this fixes the order to better comply with the way browsers construct user agent strings.

This also fixes a small bug: previously, the default Connect user-agent would be used for reflection requests, unless overridden with a --reflect-header argument. Now it uses the same user-agent as the other requests, which comes from the --user-agent argument and, lacking that, is the default Connect user-agent string plus buf/<version>. For example: connect-go/1.11.1 (go1.20.1) buf/1.26.2-dev.

…ing; also use user-agent in reflection requests
@jhump jhump requested a review from bufdev October 4, 2023 01:52
@jhump jhump merged commit b9d582d into main Oct 4, 2023
@jhump jhump deleted the jh/bufcurl-user-agent branch October 4, 2023 12:27
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

Successfully merging this pull request may close these issues.

2 participants