-
-
Notifications
You must be signed in to change notification settings - Fork 653
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
An error is thrown if a file contains non UTF-8 characters #8
Comments
Do not hesitate to make a PR to fix the encoding on Windows :) |
A possible workaround to this problem would be to encode the stdout result with base64 or hex to ensure that no invalid characters are encoded with json. The client side would have to decode the json field stdout with base64 or hex and could then output it again. The same procedure is already performed with the files. |
@flozz Would this be a desired function as I described? |
Yeah probably encoding stdout/stderr to base64 could save us here... Do you think paths (cwd) should be encoded too? :) |
Not sure, could be a potential problem. Would this be worth a PR from my side? |
Yes please make a PR if you want to implement a fix for this issue :) |
Fix released in |
File and directory names on Windows might not be UTF-8 encoded and json_encode() fails. This is what I have come up with (around line 100):
The text was updated successfully, but these errors were encountered: