Bug 14316 - Inspector's Console truncates long strings
Summary: Inspector's Console truncates long strings
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (Deprecated) (show other bugs)
Version: 523.x (Safari 3)
Hardware: All All
: P2 Normal
Assignee: Nobody
Keywords: InRadar
Depends on:
Reported: 2007-06-22 14:17 PDT by David Raso
Modified: 2008-02-11 11:58 PST (History)
0 users

See Also:

patch with changelog (7.84 KB, patch)
2008-02-11 11:03 PST, Adam Roben (:aroben)
sam: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Raso 2007-06-22 14:17:07 PDT
In the web inspector if you execute a command the return is truncated with no apparent way to see full sting.

Example if you type document.cookie - the cookie string is returned in the console but it is truncated if it is to long.
Comment 1 Timothy Hatcher 2007-06-22 20:25:25 PDT
We should have a way to click or toggle the truncation for each output. We truncate to prevent flooding the console incase the result was longer than the user expected. Maybe the default truncation length could be extended too.
Comment 2 Adam Roben (:aroben) 2007-06-24 15:04:14 PDT
I actually never meant the output to be truncated when implementing the Console (it just came along for free with using Object.describe). But I agree that it's a good idea not to flood the console if, for example, the user types "document.body.innerHTML" on a large page. Firebug doesn't truncate the output, but I think we can do better here.
Comment 3 Adam Roben (:aroben) 2008-01-29 10:57:20 PST
Comment 4 Adam Roben (:aroben) 2008-02-11 11:03:53 PST
Created attachment 19070 [details]
patch with changelog
Comment 5 Adam Roben (:aroben) 2008-02-11 11:38:00 PST
Comment on attachment 19070 [details]
patch with changelog

I should note that this patch does nothing to prevent flooding the console with a long string, since that was easier and matches Firebug's behavior.
Comment 6 Sam Weinig 2008-02-11 11:45:21 PST
Comment on attachment 19070 [details]
patch with changelog

The one change I proposed to Adam on IRC was to remove some of the _format functions that all do the same thing.  r=me.
Comment 7 Adam Roben (:aroben) 2008-02-11 11:58:58 PST
Fixed in r30146