laravel-castable-data-transfer-object icon indicating copy to clipboard operation
laravel-castable-data-transfer-object copied to clipboard

Breaking changes from thecodingmachine/safe

Open danilopolani opened this issue 2 years ago • 5 comments

Hey @jessarcher , I was raising this issue because thecodingmachine/safe just released a new minor with breaking changes, renaming the options flag in json_decode into flags and basically they won't support "named parameters" at the end of the day.

I was wondering what should be the correct solution to address this problem to submit a PR:

  1. Force the thecodingmachine/safe version to the previous one, dropping the ^1.3 support;
  2. Force thecodingmachine/safe to the current version, dropping the ^1.3 support and renaming from options to flags;
  3. Just drop the named arguments into this project and leave everything else as-is (maybe the best solution?)

Thank you!

danilopolani avatar Aug 04 '22 16:08 danilopolani

I just wanted to confirm that I am now also experiencing this issue.

Sammyjo20 avatar Aug 04 '22 19:08 Sammyjo20

I just wanted to confirm that I am now also experiencing this issue.

To temporarily solve this I forced the version of thecodingmachine/safe to be 2.0.0 in my project, probably also 2.2.2 (the previous one) would work

danilopolani avatar Aug 04 '22 19:08 danilopolani

That worked for me, thanks!

Sammyjo20 avatar Aug 04 '22 19:08 Sammyjo20

I’m only using it as a dev dependency so it’s not a big priority for me.

Sammyjo20 avatar Aug 04 '22 19:08 Sammyjo20

Hey @danilopolani, thanks for raising this.

I think option 3 is probably best.

jessarcher avatar Aug 05 '22 04:08 jessarcher

I'm experiencing the same issue, and will downgrade the thecodingmachine/safe. Thank you for the thread and your suggested solutions.

jtomek avatar Aug 09 '22 07:08 jtomek