Hi, You can have a look at go-testdeep [1] and its JSON [2] operator. go-testddep is tailored for tests, but it provides EqDeeplyError [3] function that can perhaps be useful in your use case.
json1 := json.RawMessage(`{"foo":{"a":1}}`) json2 := json.RawMessage(`{"foo":{"b":8}}`) err := td.EqDeeplyError(json1, td.JSON(json2)) → https://go.dev/play/p/6dtEB5lZOBG Regards, Max. [1]: https://go-testdeep.zetta.rocks/ [2]: https://go-testdeep.zetta.rocks/operators/json/ [3]: https://pkg.go.dev/github.com/maxatome/go-testdeep/td#EqDeeplyError Le lundi 18 septembre 2023 à 12:14:43 UTC+2, Corin Lawson a écrit : > What makes you say the existing packages are not maintained? They may > simply be complete? > > On Friday, 15 September 2023 at 5:05:10 am UTC+10 Sapna Jayavel wrote: > >> I am implementing a method find difference between two JSON objects and >> it has to drill down recursively. My usecase has very large nested JSON >> objects. Response should have the data that has changed between two JSON >> and position of the object. Do we have any Go package to support this? >> >> I looked at couple of packages available out there but seems ones are not >> currently maintained. >> > -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/30ea284b-254d-4fe7-b514-4762fd00b43an%40googlegroups.com.