kratos icon indicating copy to clipboard operation
kratos copied to clipboard

Jsonnet template `ctx` shape for http notification body breaking changes since 1.1

Open WoodyWoodsta opened this issue 11 months ago • 2 comments

Preflight checklist

Ory Network Project

N/A

Describe the bug

Upgrading to 1.1 broke my jsonnet template for sending a notification via the http delivery strategy. Before 1.1, and as per the documentation here, the shape of ctx passed into the template contains at least keys TemplateType and TemplateData.Identity.

However, in 1.1, we now get those keys in a different casing, template_type and template_data.identity.

I couldn't find any mention of this in the 1.1 changelog.

Either the documentation needs to be updated, or this is a regression which needs to be fixed.

Reproducing the bug

Upgrade to 1.1

Relevant log output

No response

Relevant configuration

No response

Version

1.1

On which operating system are you observing this issue?

None

In which environment are you deploying?

Kubernetes with Helm

Additional Context

No response

WoodyWoodsta avatar Mar 10 '24 12:03 WoodyWoodsta

The commit in question: https://github.com/ory/kratos/commit/84149c4b420ea89f0a16a579c017a8e7e1670204 It looks like this was changed without the necessary precautions by @aeneasr, there should really have been a breaking change note and ideally the "old" keys for some transition period. As the commit was already part of the v1.1.0 release, there is probably no point in back-porting the old keys.

Regardless, we're very sorry of the inconvenience this has caused, this one has just slipped through.

zepatrik avatar Jun 19 '24 09:06 zepatrik

No problem at all - easy fix, just came as a surprise and had to do a bit of rooting around to understand the issue :)

WoodyWoodsta avatar Jun 19 '24 09:06 WoodyWoodsta