Skip to content
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

Allow thecodingmachine/safe 2 #142

Merged
merged 3 commits into from
Nov 27, 2024
Merged

Conversation

holtkamp
Copy link
Contributor

To prevent a lot of deprecation messages when running version 1 on PHP 8.4

To prevent a lot of deprecation messages when running version 1 on PHP 8.4
@boring-cyborg boring-cyborg bot added Dependencies 📦 Pull requests that update a dependency file JSON 👨‍💼 PHP 🐘 Hypertext Pre Processor labels Nov 25, 2024
Copy link
Owner

@WyriHaximus WyriHaximus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need to review how best to move away from safe anyway in the long term. But for now can you also made sure composer.lock is updated with composer update --lock?

@holtkamp
Copy link
Contributor Author

Aah, yeah, ofcourse, did not see the composer.lock was included.

Tried to amend my last commit, feel free to squash commits to prevent GIT history pollution...

@WyriHaximus WyriHaximus self-requested a review November 27, 2024 22:50
@WyriHaximus WyriHaximus added this to the 5.0.0 milestone Nov 27, 2024
@WyriHaximus WyriHaximus merged commit 569b6d8 into WyriHaximus:5.x Nov 27, 2024
107 checks passed
@holtkamp holtkamp deleted the patch-1 branch November 28, 2024 17:43
@holtkamp
Copy link
Contributor Author

@WyriHaximus
Copy link
Owner

@WyriHaximus thanks! Can this also be tagged as a release in the version 4 branch? I suppose 4.0.4?

Not on this branch, this is for the upcoming v5. Could you create a PR for the 4.x branch so I can get a new v4 version out the door?

@holtkamp
Copy link
Contributor Author

Sure, see #143

@holtkamp
Copy link
Contributor Author

holtkamp commented Dec 2, 2024

@WyriHaximus you wrote:

Need to review how best to move away from safe anyway in the long term.

Both json_encode() and json_decode() now allow a flag to throw exceptions, that might be useful to start with.

This might be an interesting discussion though: thecodingmachine/safe#437

Then the following functions that use the Safe dependency remain (scanned quickly):

  • Safe\base64_decode() in:
    -- WyriHaximus\React\ChildProcess\Messenger\ChildProcess\ArgvEncoder
    -- WyriHaximus\React\ChildProcess\Messenger\Messages
  • Safe\scandir() in WyriHaximus\FileDescriptors\ScanDir
  • Safe\sprintf() in WyriHaximus\React\ChildProcess\Messenger\Factory

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Dependencies 📦 Pull requests that update a dependency file JSON 👨‍💼 PHP 🐘 Hypertext Pre Processor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants