Closed
Bug 762068
Opened 13 years ago
Closed 13 years ago
Unable to disable search suggestions - java.net.MalformedURLException: Protocol not found: null
Categories
(Firefox for Android Graveyard :: General, defect)
Tracking
(firefox16 verified)
VERIFIED
FIXED
Firefox 16
Tracking | Status | |
---|---|---|
firefox16 | --- | verified |
People
(Reporter: aaronmt, Assigned: bnicholson)
References
Details
(Keywords: reproducible)
Attachments
(3 files)
3.80 KB,
patch
|
mfinkle
:
review+
|
Details | Diff | Splinter Review |
6.51 KB,
patch
|
mfinkle
:
review+
|
Details | Diff | Splinter Review |
1.58 KB,
patch
|
mfinkle
:
review+
|
Details | Diff | Splinter Review |
W/GeckoSuggestClient( 2432): java.net.MalformedURLException: Protocol not found: null
W/GeckoSuggestClient( 2432): at java.net.URL.<init>(URL.java:178)
W/GeckoSuggestClient( 2432): at java.net.URL.<init>(URL.java:127)
W/GeckoSuggestClient( 2432): at org.mozilla.gecko.SuggestClient.query(SuggestClient.java:72)
W/GeckoSuggestClient( 2432): at org.mozilla.gecko.AwesomeBar$4$1.doInBackground(AwesomeBar.java:193)
W/GeckoSuggestClient( 2432): at org.mozilla.gecko.AwesomeBar$4$1.doInBackground(AwesomeBar.java:191)
W/GeckoSuggestClient( 2432): at android.os.AsyncTask$2.call(AsyncTask.java:264)
W/GeckoSuggestClient( 2432): at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:305)
W/GeckoSuggestClient( 2432): at java.util.concurrent.FutureTask.run(FutureTask.java:137)
W/GeckoSuggestClient( 2432): at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:208)
W/GeckoSuggestClient( 2432): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1076)
W/GeckoSuggestClient( 2432): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:569)
W/GeckoSuggestClient( 2432): at java.lang.Thread.run(Thread.java:856)
STR: Disable 'Search Suggestions' in settings and then proceed to due a search
--
Tested via
Asus Transformer Prime TF201
20120606065339
http://hg.mozilla.org/integration/mozilla-inbound/rev/7d817c805af5
Assignee | ||
Comment 1•13 years ago
|
||
This disables the suggest engine from being saved to shared prefs. I had added this to allow search suggestions to work immediately at startup before Gecko is loaded, but I don't think it's worth the extra cruft to support the few seconds where this matters. Plus, the icon doesn't appear, so it looks bad.
Assignee: nobody → bnicholson
Attachment #632065 -
Flags: review?(mark.finkle)
Assignee | ||
Comment 2•13 years ago
|
||
For the same reasons, this also removes the static search engine data. This means that we must now wait for a response from Gecko every time we show the AwesomeScreen before we show suggestions, but this hasn't noticeably affected suggestions from my testing.
Attachment #632082 -
Flags: review?(mark.finkle)
Assignee | ||
Comment 3•13 years ago
|
||
This is what actually caused the bug here. Apparently, optString() still returns the string "null" if the JSON value is null.
Attachment #632084 -
Flags: review?(mark.finkle)
Assignee | ||
Comment 4•13 years ago
|
||
This is supposed to be in the 2nd patch, not the 3rd:
+ if (suggestTemplate != null)
+ mSuggestClient = new SuggestClient(GeckoApp.mAppContext, suggestTemplate, SUGGESTION_TIMEOUT, SUGGESTION_MAX);
Just made this change locally.
Comment 5•13 years ago
|
||
Comment on attachment 632065 [details] [diff] [review]
Part 1: Don't save suggest engine to shared prefs
I agree that this is probably overkill
Attachment #632065 -
Flags: review?(mark.finkle) → review+
Comment 6•13 years ago
|
||
Comment on attachment 632082 [details] [diff] [review]
Part 2: Remove static search engine data
Yeah, make sure the mSuggestClient is created in this patch
Attachment #632082 -
Flags: review?(mark.finkle) → review+
Comment 7•13 years ago
|
||
Comment on attachment 632084 [details] [diff] [review]
Part 3: Replace optString() with null checks
Ah, so optString only returns an empty string if the field does not exist.
Attachment #632084 -
Flags: review?(mark.finkle) → review+
Assignee | ||
Comment 8•13 years ago
|
||
Assignee | ||
Updated•13 years ago
|
Target Milestone: --- → Firefox 16
Comment 9•13 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/5273e295087c
https://hg.mozilla.org/mozilla-central/rev/ec5e7f934d20
https://hg.mozilla.org/mozilla-central/rev/e04eb0eb59dd
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Updated•13 years ago
|
Reporter | ||
Updated•12 years ago
|
Status: RESOLVED → VERIFIED
Updated•11 years ago
|
tracking-fennec: ? → ---
Updated•4 years ago
|
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•