Closed
Bug 243510
Opened 20 years ago
Closed 20 years ago
Folders nested incorrectly when importing bookmarks from Firefox
Categories
(Camino Graveyard :: Bookmarks, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
Camino0.9
People
(Reporter: rhostik, Assigned: mikepinkerton)
References
Details
(Whiteboard: needs to land on trunk and branch)
Attachments
(2 files)
(deleted),
text/plain
|
Details | |
(deleted),
patch
|
me
:
review+
Usul
:
review+
mikepinkerton
:
superreview+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.8a) Gecko/20040512 Camino/0.7+
Build Identifier: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.8a) Gecko/20040512 Camino/0.7+
When I try to import my Firefox bookmarks, the folders are always nested
incorrectly. Some of these bookmarks are over 5 years old, dating back to IE4.
Looking at the file, I can see at least 3 different types of formatting style.
I will attach a file showing a cut down version of the bookmarks.html file. As a
clue to what's going wrong, if you hover your cursor of the "Proxies" folder in
"Show All Bookmarks" window, the helper dialog shows "/H3>" instead of "Proxies".
This is how the nesting is supposed to look:
Bookmarks Toolbar
Internet
Proxies
Blogs
Shopping
dvd and video
music
Hard to Find
Amazon UK
Amazon US
Walmart
comparison
Retro Rebels
Football
And this is how it turns out:
Bookmarks Toolbar
Internet
Proxies
Blogs
Shopping
dvd and video
music
Hard to Find
Amazon UK
Amazon US
Walmart
comparison
Retro Rebels
Football
Reproducible: Always
Steps to Reproduce:
1.Camino -> Import Bookmarks
2.Use the attached bookmarks.html file
3.
Actual Results:
Bookmarks were imported but folder nesting was incorrect.
OS 10.3.3
Assignee | ||
Updated•20 years ago
|
Target Milestone: --- → Camino0.9
I can't reproduce this problem with Firefox 0.8 and a bunch of nested folders.
They always import correctly.
Comment 4•20 years ago
|
||
Josh: are you using the attached bookmark file?
I can reproduce with this file. Just glancing at where things go wrong and
looking at the file, I'd guess that the completely empty <dd> tags are fouling
up the parser.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Stuart, your diagnosis seems to be correct. I removed all the empty <DD> tags.
The attached file and my complete bookmarks file were then imported correctly.
Thanks.
Over to Stuart, since he seems to know the most about what is going on here.
Assignee: pinkerton → stuart.morgan
Updated•20 years ago
|
Status: NEW → ASSIGNED
Comment 7•20 years ago
|
||
Giving my bugs back to pink.
Assignee: stuart.morgan → pinkerton
Status: ASSIGNED → NEW
Attachment #157351 -
Flags: review?(me)
The problem is that NSScanner ignores whitespace and newlines by default.
Whoever wrote the import code must have just forgotten that. So the parser
attempts to scan from a blank <DD> tag up to the next tag, but it doesn't
actually scan past any whitespace. Thus when it assumes its grabbing a tag's
text (e.g. "<TD" or whatever) its actually grabbing whitespace. The good news is
the author seems to have assumed it didn't skip whitespace in all the rest of
the code, so just making that assumption true doesn't seem to break anything else.
Comment 10•20 years ago
|
||
Patch work as advertised. Bug is gone using the attached test bookmarks file.
Comment 11•20 years ago
|
||
Comment on attachment 157351 [details] [diff] [review]
patch v1.0
This fix makes sense and works as described.
Attachment #157351 -
Flags: review?(me) → review+
Updated•20 years ago
|
Attachment #157351 -
Flags: superreview?(pinkerton)
Assignee | ||
Comment 12•20 years ago
|
||
Comment on attachment 157351 [details] [diff] [review]
patch v1.0
sr=pink
Attachment #157351 -
Flags: superreview?(pinkerton)
Attachment #157351 -
Flags: superreview+
Assignee | ||
Comment 13•20 years ago
|
||
landed on trunk and branch.
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•