Skip to content
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

Fix ruleset rule not respecting position "0" #236

Merged
merged 1 commit into from
Sep 9, 2020

Conversation

zane-deg
Copy link
Contributor

During the JSON marshal of a RulesetRule, a Position with the value of 0 is considered empty and is not sent in the POST or PUT payload. Using a pointer allows the JSON marshal function to distinguish between an empty value and a default value.

I'm not sure how this change would be handled as it isn't really backwards compatible. Happy to hear any thoughts or opinions.

During the JSON marshal of a RulesetRule a Position with the value of "0" is considered empty and is not sent in the POST or PUT payload.
@theckman
Copy link
Collaborator

theckman commented Aug 27, 2020

Yeah that's a bummer, but understandable. If it weren't such a big deal to have consumers upgrade to v2.0.0, I'd be OK with merging this and starting the v2 branch a la Chrome.

What we may need to do is cut a breaking minor release, and treat it like a necessary 1.0 bugfix. What thoughts do others have?

@dobs
Copy link
Contributor

dobs commented Sep 9, 2020

@theckman Agreed that a minor release sounds reasonable.

I believe there are other breaking changes we'd want to incorporate into a full V2 release, and at the very least a more thorough pass on properly handling optional fields.

Barring any objections I'll cut v1.3.0 later today.

@dobs dobs merged commit 1566007 into PagerDuty:master Sep 9, 2020
@zane-deg zane-deg deleted the fix-ruleset-rule-position branch November 24, 2020 22:22
@theckman theckman added this to the v1.4.0 milestone Mar 10, 2021
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.

3 participants