You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using PtyCommandLine, unlike GeneralCommandLine, the command output is fully simulated as a TTY. While this simulation enables features such as colored output, it also causes an issue when dealing with long output (currently, lines longer than 80 characters). The text is automatically truncated and wrapped to new lines.
When reading the stdout directly, this causes the output that should not be wrapped into multiple lines to be split, which leads to JSON parsing errors.
Here's an example when compiling a smart contract:
aptos move compile
Although it finishes successfully, it still throws an exception:
{
"Result": [
"0000000000000000000000000000000000000000000000000000000000012345::aaa_bbb_c <-- auto wrapped here
cc_ddd_eee"
]
}
com.fasterxml.jackson.core.JsonParseException: Illegal unquoted character ((CTRL-CHAR, code 10)): has to be escaped using backslash to be included in string value
at [Source: REDACTED (`StreamReadFeature.INCLUDE_SOURCE_IN_LOCATION` disabled); line: 3, column: 81]
The text was updated successfully, but these errors were encountered:
When using
PtyCommandLine
, unlikeGeneralCommandLine
, the command output is fully simulated as a TTY. While this simulation enables features such as colored output, it also causes an issue when dealing with long output (currently, lines longer than 80 characters). The text is automatically truncated and wrapped to new lines.When reading the
stdout
directly, this causes the output that should not be wrapped into multiple lines to be split, which leads to JSON parsing errors.Here's an example when compiling a smart contract:
Although it finishes successfully, it still throws an exception:
The text was updated successfully, but these errors were encountered: