crossplane-contrib / function-patch-and-transform

A patch & transform composition function
https://crossplane.io
Apache License 2.0
23 stars 24 forks source link

round-trip the fieldPath value in FromFieldPath patches through integer-preserving JSON unmarhsal #105

Closed ravilr closed 4 months ago

ravilr commented 5 months ago

this fixes the remaining issue reported in #101 w.r.t appendSlice patch policy in function-p-and-t having different behavior than the native P&T.

As explained in https://github.com/crossplane-contrib/function-patch-and-transform/issues/101#issuecomment-2022468812, the from source field value is being round-trip'ed through Kubernetes JSON decoder, so that the json integers are unmarshaled as int64 consistent with to/dest value handling here.

ravilr commented 5 months ago

@phisco @negz PTAL.