-
Notifications
You must be signed in to change notification settings - Fork 64
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
Follow-up to gzip encoding of request body #343
Conversation
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.
🌟
"github.com/hashicorp/go-multierror" | ||
"github.com/jig/teereadcloser" | ||
ioaux "github.com/jig/teereadcloser" |
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.
It looks like goimports
is what keeps adding the ioaux
alias.
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.
And I think it's correct, since the package defined in teereadcloser
is called ioaux
: https://github.com/jig/teereadcloser/blob/953720c48e058a8869b07daa7db756dc7823b2e1/teereadcloser.go#L5
Thanks! |
* Add semver to go.mod * Bring back tests for sourcegraphVersionCheck * Extract version check into public function * Move check for gzip compression to campaigns service * Fix unmarshaling of sourcegraph version * Add CHANGELOG
This is a follow-up to #336 and addresses this comment #336 (comment) and the broken build (see #336 (comment)) by
api.Client
(vs. trying to encode every request)gzip: bool
flag a property of theapi.Request
struct to fix the data raceapi.Client
and moving it into thecampaigns.Service
where it's used to determine whether gzip compression should be used or notsourcegraphVersionCheck
functioncampaigns.Service
to query the version