-
Notifications
You must be signed in to change notification settings - Fork 24
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
Implement registrar methods for Domain Prices API #103
Conversation
This commit introduces a new client method for our Domain Prices API: - Registrar.GetDomainPrices - Retrieves the prices for a domain. It also includes if the domain is premium or not in the response.
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.
👏 Just make sure CI passes before merging :)
Specs are broken. Please address them first, then re-add for review. |
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.
Specs are broken.
The work to fix the cause of the broken specs are being done at #104. Maybe we can allow 1.5 to fail for now until we finish the Transfer-Encoding work. wdyt @DXTimer @ggalmazor ? |
Co-authored-by: Santiago Traversa <[email protected]>
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.
Works like a charm
Data *DomainPrice `json:"data"` | ||
} | ||
|
||
func (s *RegistrarService) GetDomainPrices(ctx context.Context, accountID string, domainName string) (*DomainPriceResponse, error) { |
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.
You are missing the docs here. It breaks the lint.
➜ dnsimple-go git:(implement_domain_prices) ✗ golint ./...
dnsimple/registrar.go:110:1: exported method RegistrarService.GetDomainPrices should have comment or be unexported
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.
@weppos thanks!
shouldn't we add this on CI? thanks
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.
Yes, it would be great. Sadly, it's a bit complicated:
- I tried to add a
Makefile
in the past b7733b8, sadly once you add aMakefile
Travis will rely entirely on it and you will need a non trivial amount of customization to make the build pass in both module and non-module versions. Things would be easier if we would only use module-aware versions (1.11 or above). golint
is not enough to break the build. It's a highly recommended standard. We could add it asgolint ./...
in the travis.yml file, but it would cause the build to break if anything is invalid (and right now we have one lint warning). The current warning is actually a false positive due to a naming conflict between the webook package and the Webhook as result of the Webhook API. I am not sure how to ignore this as golint doesn't have a way to address false positives. We should probably upgrade togolangci-lint
which instead does.
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.
👍
Please add the missing docs.
Co-authored-by: Simone Carletti <[email protected]>
This commit introduces a new client method for our Domain Prices API:
It also includes if the domain is premium or not in the response.