-
Notifications
You must be signed in to change notification settings - Fork 69
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
BREAKING CHANGE: use string instead of enum for Version
#561
Conversation
TypeScript does not consider enum values equivalent, even if the string representation is the same. So, when a module imports `cloudevents` and also has a dependency on `cloudevents` this can cause conflicts where the `CloudEvent.version` attribute is not considered equal when, in fact, it is. Changing the `enum` to a string is pretty straightforward, but should be considered a breaking change since TypeScript dependents will potentially fail the build with a change like this. Signed-off-by: Lance Ball <lball@redhat.com>
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.
LGTM
@lance looks like the merging of this didn't have the effect we wanted(creating a major bump PR) |
I noticed that. I should have used |
maybe that "empty commit release as version" workflow, that we've done before? |
This is an empty commit that provides a reference to cloudevents#561 which was not considered a breaking change by release-please. Release-As: 8.0.0 Signed-off-by: Lance Ball <lball@redhat.com>
This is an empty commit that provides a reference to #561 which was not considered a breaking change by release-please. Release-As: 8.0.0 Signed-off-by: Lance Ball <lball@redhat.com>
That didn't seem to work either... Hmm |
maybe the prefix of the commit should just be |
TypeScript does not consider enum values equivalent, even if the string representation is the same. So, when a module imports
cloudevents
and also has a dependency on another module which also has a dependency oncloudevents
this can cause conflicts where theCloudEvent.version
attribute is not considered equal when, in fact, it is.Changing the
enum
to a string is pretty straightforward, but should be considered a breaking change since TypeScript dependents will potentially fail the build with a change like this.See: knative/func#1873 (comment)
Fixes: #323