Page 1 of 1
[NOT A BUG] Debug output window limitation ?
Posted: Wed Jun 19, 2024 12:38 am
by boddhi
Since version PB 6.03, there seems to be a limitation in the possibility of displaying content in one shot in the debug output window.
As an example, with 6.02, after an HTTP request, I retrieve an unformatted JSON string of 145402 characters.
A ComposeJSON(#JSON,#PB_JSON_PrettyPrint) produces a string of 451290 characters with 7609 lines displayed without any problem with Debug.
With versions beyond it, Debug only displays 257722 characters with 4356 lines.
Is this limitation since 6.03 deliberate? imposed by a technical constraint? or is it abnormal?
Thanks.
// Moved from "Bugs - IDE" to "Coding Questions" (Kiffi)
Re: Debug output window limitation ?
Posted: Wed Jun 19, 2024 8:28 am
by tored
Spent some time on this one, wondered why my downloaded file was only half of what it should be. Lot of debugging on the downloading code before realising it was the debug output that truncated my file.

Re: Debug output window limitation ?
Posted: Wed Jun 19, 2024 9:08 am
by boddhi
tored wrote:
Spent some time on this one, wondered why my downloaded file was only half of what it should be. Lot of debugging on the downloading code before realising it was the debug output that truncated my file.
While debugging, a SaveXXXX operation is often the best thing to do to make sure that what we're getting back is correct.

Re: Debug output window limitation ?
Posted: Wed Jun 19, 2024 9:20 am
by mk-soft
The debug output has been limited with the current version.
Re: Debug output window limitation ?
Posted: Wed Jun 19, 2024 9:58 am
by spikey
Don't forget that the 'Library Viewer' can display JSON in full, XML too. It can be called inline to a specific target with ShowLibraryViewer("JSON").
Re: Debug output window limitation ?
Posted: Wed Jun 19, 2024 10:14 am
by BarryG
boddhi wrote: Wed Jun 19, 2024 12:38 amimposed by a technical constraint?
Yes ->
https://www.purebasic.fr/english/viewto ... 90#p607990
Re: Debug output window limitation ?
Posted: Wed Jun 19, 2024 10:29 am
by boddhi
mk-soft wrote:
The debug output has been limited with the current version.
OK, I'll take note.
spikey wrote:
Don't forget that the 'Library Viewer' can display JSON in full, XML too. It can be called inline to a specific target with ShowLibraryViewer("JSON").
I know, I know; I refer to JSON just for the example.
Ok, now, there is an good reason.
I did search before posting, but I finally didn't use the right keywords.
Thanks to all.

Re: [NOT A BUG] Debug output window limitation ?
Posted: Sun Jun 23, 2024 10:51 am
by tored
Fred, would it be possible to indicate the the output in the debug window have been truncated? Like three dots ... appended to the end or something similar.
Re: [NOT A BUG] Debug output window limitation ?
Posted: Sun Jun 23, 2024 12:35 pm
by BarryG
No point because you can't scroll to the right of the debug output to see the 3 dots if they were there:
Code: Select all
Debug "start"+Space(2000000)+"end"