-
Notifications
You must be signed in to change notification settings - Fork 12
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
trconv.Atoi: parsing ]]></stream>": invalid syntax #31
Comments
Same here. I assume this is caused by xdebug 2.8? |
It happends with XDebug 3.0 too ... hard to debug and actually I don't really understand the problem. Look like related to protocol string length ... need to ready again the XDebug spec ... |
I tried to get this fixed, but I failed, due to my lack of GO knowledge. I'd like to share my findings, so maybe some else can fix it. Main issue is the current handling of the incoming stream buffer from xdebug. The current implementation assumes that each chunk of the stream contains maximum ONE package. The latest change (PR #20) has improved it, in case the chunk does not contain all information of the package. Issue is now, that the chunk contains more than ONE package, which is not handled. So the string sent to the mapper might contain a incomplete package, which is not parseable. e.g:
For some reason this might have changed in the past, as this code was actually working before. Maybe it's something special due to a configuration or environment. I tried to fix this by iterating over all package parts and checking if the last one is complete. If not to read the next chunk from the stream until it's complete. But this can also lead to a "leftover" package part. And as I said, it doesn't work as expected. (See: dlubitz@6617a03) Maybe this helps someone else to solve the issue. |
For me increasing the buffer size which is now set to 64KB resolved this issue (see line: https://github.com/dfeyer/flow-debugproxy/blob/master/xdebugproxy/xdebugproxy.go#L99) The size of the message from the Debugger >>> IDE would exceeded this buffer size (76880 bytes in my case):
As a quickfix I doubled this size to 128KB (0x20000) |
I know there is already a solved issue here that mentions the issue with trconv.Atoi: parsing is fixed.
but i now tried for quite a while to get this running.
But i always get these errors in the debug output of the container running the debugproxy:
which comes right after a line with this content:
and just now i got the error (with an extremely long gibberish value) after this line:
when i base64 decode the line of my first logged line, i get something like a linebreak or similar.
if i decode the second logged line i get
Content-type: text/html; charset=UTF-8
But i don't know if these are even lines that are supposed to appear in these base64 values. So not sure if i still have some wrong configuration or if anything else is wrong here.Using PHP v7.3.27
xdebug v2.8.0
in a docker environment
The text was updated successfully, but these errors were encountered: