Closed Bug 801615 Opened 12 years ago Closed 12 years ago

Edited contacts can't be saved if address book has lists

Categories

(SeaMonkey :: MailNews: Address Book & Contacts, defect)

defect
Not set
major

Tracking

(seamonkey2.13 fixed, seamonkey2.14 verified, seamonkey2.15 fixed)

RESOLVED FIXED
seamonkey2.16
Tracking Status
seamonkey2.13 --- fixed
seamonkey2.14 --- verified
seamonkey2.15 --- fixed

People

(Reporter: Hb, Assigned: iannbugzilla)

References

Details

(Keywords: regression)

Attachments

(1 file)

After upgrading to version 2.13.1 edited contacts can't be saved in existing address books. The OK button doesn't work. Creating new contacts in existing address books is possible, but editing them afterwards fails too.

In address books created after the upgrade editing contacts works fine.
This error happens in new address books to if they contain mailing lists. And old address books are not affected if they don't have mailing lists.
Summary: Edited contacts can't be saved → Edited contacts can't be saved if address book has lists
Confirmed.

Nothing shows in Error Console.
SeaMonkey 2.12.1 & (at least some) 2.13a1 work correctly, but broken by (at some point in?) 2.13a2, so looks like a regression.

(Not exact regression range, just what I had on hand.)

Works:
Mozilla/5.0 (Windows NT 5.1; rv:16.0) Gecko/16.0 Firefox/16.0 SeaMonkey/2.13a1
Build identifier: 20120712003002

http://hg.mozilla.org/mozilla-central/rev/46804c31366b

Broken:
Mozilla/5.0 (Windows NT 5.1; rv:16.0) Gecko/16.0 Firefox/16.0 SeaMonkey/2.13a2
Build identifier: 20120723013003

http://hg.mozilla.org/releases/mozilla-aurora/rev/1580771f753b
Ian touched a lot of addressbook code in that time frame. CC IanN
I'd bet someone used an editor without (variable occurrence) highlighting to create this:

http://mxr.mozilla.org/comm-central/source/suite/mailnews/addrbook/abCardOverlay.js#186
http://mxr.mozilla.org/comm-central/source/suite/mailnews/addrbook/abCardOverlay.js#191

These are the only two mentions of "subdir" in that file...

I think this one's easy. Takers? I won't get to this until tomorrow, so here's your chance!
Depends on: 761852
OS: Windows 7 → All
Hardware: x86_64 → All
Version: SeaMonkey 2.13 Branch → Trunk
[Approval Request Comment]
Regression caused by (bug #): 761852
User impact if declined: Edited contacts cannot be saved
Testing completed (on m-c, etc.): Yes 
Risk to taking this patch (and alternatives if risky): None
String changes made by this patch: None
Assignee: nobody → iann_bugzilla
Status: NEW → ASSIGNED
Attachment #671634 - Flags: review?(neil)
Attachment #671634 - Flags: approval-comm-release?
Attachment #671634 - Flags: approval-comm-beta?
Attachment #671634 - Flags: approval-comm-aurora?
(In reply to Jens Hatlak (:InvisibleSmiley) from comment #7)
> I'd bet someone used an editor without (variable occurrence) highlighting
Does vim have such an extension?

> to
> create this:
> 
> http://mxr.mozilla.org/comm-central/source/suite/mailnews/addrbook/
> abCardOverlay.js#186
> http://mxr.mozilla.org/comm-central/source/suite/mailnews/addrbook/
> abCardOverlay.js#191
> 
> These are the only two mentions of "subdir" in that file...
> 
> I think this one's easy. Takers? I won't get to this until tomorrow, so
> here's your chance!

Yeah, I'd already got there, was just waiting for trees to compile to test before attaching.
Attachment #671634 - Flags: review?(neil)
Attachment #671634 - Flags: review+
Attachment #671634 - Flags: approval-comm-aurora?
Attachment #671634 - Flags: approval-comm-aurora+
Comment on attachment 671634 [details] [diff] [review]
Fix typos [Checked into comm-aurora: Comment 10 , comm-beta & trunk: Comment 18 , comm-release: Comment 29]

http://hg.mozilla.org/releases/comm-aurora/rev/ea12aa746521
Attachment #671634 - Attachment description: Fix typos → Fix typos [Checked into comm-aurora: Comment 10]
Comment on attachment 671634 [details] [diff] [review]
Fix typos [Checked into comm-aurora: Comment 10 , comm-beta & trunk: Comment 18 , comm-release: Comment 29]

Review of attachment 671634 [details] [diff] [review]:
-----------------------------------------------------------------

a+ for beta, I'll leave the -release flag open so that if we have another .x release we can triage then. I suspect we'd take it for -release though if we do, but I won't spin a release *just* for this.
Attachment #671634 - Flags: approval-comm-beta? → approval-comm-beta+
(In reply to Ian Neal from comment #9)
> (In reply to Jens Hatlak (:InvisibleSmiley) from comment #7)
> > I'd bet someone used an editor without (variable occurrence) highlighting
> Does vim have such an extension?

Not sure about real variable highlighting like tools like Eclipse provide for some languages. But word highlighting should do. Just ":set hlsearch" (or ":set hls" in short), then "*" (jumps to next occurrence) or "*``" (jumps back). See http://vim.wikia.com/wiki/Highlight_all_search_pattern_matches for details.

Personally I'm not using vim for larger editing sessions, but don't use a full-blown IDE for Mozilla-related coding either. SciTE and Notepad++ provide word occurrence highlighting out of the box (just double-click a word), and SciTE works on both Windows and Linux/Unix, with the possibility to share configuration files between platforms even.
Thanks to all for the quick solution.

I hacked the patch in omni.ja with no result.  After disabling an Add-On and restarting the browser the patch worked.  The "disabling an Add-On" is only a workaround for clearing some cache. 

1. a)
Why isn't a solution for the "bad cache after altering omni.ja problem" described here https://developer.mozilla.org/en-US/docs/Mozilla/About_omni.ja_%28formerly_omni.jar%29 ?

1. b)
What is the best way to make changes in omni.ja work?

2. 
Now a contact can't be edited if its source picture is absent as said in bug 691141.

(In reply to therube from comment #2)
> Nothing shows in Error Console.

I did see an error message after setting dom.report_all_js_exceptions = true
SeaMonkey 2.13.1 upgrade.
Now I can not save changes to address book records.
Close and reopen SeaMonkey. Same.
Reboot system. Same.

Went back to SeaMonkey 2.13.
Same problem.

I'm running SeaMonkey under Windows XP Pro with all patches installed.

The OK button (used to save changes) visually depresses when clicked, but the changes are not saved and the record does not close.

My address book has been around for years. It gets large over time--I currently have 1393 contacts. So my "old" address book has this "new" problem.

I also have several email address lists, but I've also had these for years. So I speculate the elists did not create the problem.

If you want any log files, I'll send them along. But you will need to tell me the file name and its usual location.
(In reply to Michael Carr from comment #15)
The error is found, see attachment 671634 [details] [diff] [review].  For an instant solution you can hack the omni.ja file in Seamonkeys program folder with an unzipper and an editor.  Or you can store contact updates temporarily in an address book without mailing lists until an updated program version is released.
I installed lower versions until SeaMonkey started working again.

At 2.12.1 the problem went away.

This tells me the problem is in the SeaMonkey program, not in a corrupted address book data base, nor a corrupted setting inside "about:config".

Thanks to everyone who is working on finding the bug and fixing it.
Comment on attachment 671634 [details] [diff] [review]
Fix typos [Checked into comm-aurora: Comment 10 , comm-beta & trunk: Comment 18 , comm-release: Comment 29]

http://hg.mozilla.org/comm-central/rev/f2e48ec916ba
http://hg.mozilla.org/releases/comm-beta/rev/e9a98a948e7e
Attachment #671634 - Attachment description: Fix typos [Checked into comm-aurora: Comment 10] → Fix typos [Checked into comm-aurora: Comment 10 , comm-beta & trunk: Comment 18]
Target Milestone: --- → seamonkey2.14
Target Milestone: seamonkey2.14 → seamonkey2.16
I'm using Windows 8RP and the same issue as above. No problem changes addresses in a 'book' without 'lists' - but definitely 'ME TOO' for address books with lists.
(In reply to Hb from comment #1)
> This error happens in new address books to if they contain mailing lists.
> And old address books are not affected if they don't have mailing lists.

Hello,
Sorry, it happens in my old address book's (I dont create new address book) : the old are affected !
Bertrand
(In reply to bertranddepommery from comment #21)

Has your old address book a mailing list card?
(In reply to Hb from comment #22)
> (In reply to bertranddepommery from comment #21)
> 
> Has your old address book a mailing list card?

In my all address book's, there is both card indivudual and listes for mailing.
Hello,
the listes for mailing can be modified (add or delete a name in the liste).
We can creat a new individual card or delete an indidual card, but we can't modify any card
Bertrand
Excuse me I'm testing the address book :
In e new address book we can creat a new indidual card and we can also modify then
In an adress book without mailing listes that in ok and When we create one maling list then modifing a individual card become impossible (delete all the list, the modify become possible).
The bug is there !
Thanks everyone but we don't need further input at this time. The problem is very well understood and has already been fixed in later versions, namely 2.14 Beta 1. This means it will be fixed in 2.14 at the latest. If we do a 2.13.2 release, the fix might already be included in that version.
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Comment on attachment 671634 [details] [diff] [review]
Fix typos [Checked into comm-aurora: Comment 10 , comm-beta & trunk: Comment 18 , comm-release: Comment 29]

Review of attachment 671634 [details] [diff] [review]:
-----------------------------------------------------------------

Changed my mind on the "I won't spin a release just for this". This issue seems to be more impactful in the wild than I expected. We might also have a few useful ride-alongs here. Land at your earliest convenience
Attachment #671634 - Flags: approval-comm-release? → approval-comm-release+
Comment on attachment 671634 [details] [diff] [review]
Fix typos [Checked into comm-aurora: Comment 10 , comm-beta & trunk: Comment 18 , comm-release: Comment 29]

http://hg.mozilla.org/releases/comm-release/rev/2d80b9fec104
Attachment #671634 - Attachment description: Fix typos [Checked into comm-aurora: Comment 10 , comm-beta & trunk: Comment 18] → Fix typos [Checked into comm-aurora: Comment 10 , comm-beta & trunk: Comment 18 , comm-release: Comment 29]
(In reply to Hb from comment #16)
> (In reply to Michael Carr from comment #15)
> The error is found, see attachment 671634 [details] [diff] [review].  For an
> instant solution you can hack the omni.ja file in Seamonkeys program folder
> with an unzipper and an editor.  Or you can store contact updates
> temporarily in an address book without mailing lists until an updated
> program version is released.

I hope I am just an idiot. Updates work in a new book with no lists, but the hack mentioned doesn't seem to do it if list are present -- for me, anyway. 'omni.ja' updated and confirmed change; restarted Seamonkey several times, having disabled and enabled add-ons each time.
(In reply to nva@vtresources.com from comment #31)
> (In reply to Hb from comment #16)
> > (In reply to Michael Carr from comment #15)
> > The error is found, see attachment 671634 [details] [diff] [review].  For an
> > instant solution you can hack the omni.ja file in Seamonkeys program folder
> > with an unzipper and an editor.  Or you can store contact updates
> > temporarily in an address book without mailing lists until an updated
> > program version is released.
> 
> I hope I am just an idiot. Updates work in a new book with no lists, but the
> hack mentioned doesn't seem to do it if list are present -- for me, anyway.
> 'omni.ja' updated and confirmed change; restarted Seamonkey several times,
> having disabled and enabled add-ons each time.

Let's see. Here is how I would do it. If it doesn't work this way, then *both* of us are idiots.
omni.ja is just a zipfile under another name, so the following ought to do it:
0. Make sure that SeaMonkey is fully closed. You may want to check it using "ps -lC seamonkey" under Linux or Mac, or the Processes tab (sorted by process name) of the Windows Task Manager, which IIUC can be started by Ctrl+Alt+Del. (It may take several minutes after the last SeaMonkey window closes; how long may depend on how many tabs were open.)
1. Create an empty new directory.
2. Unzip omni.ja (found in your installation directory, see http://kb.mozillazine.org/Installation_directory for examples) into that new directory.
3. Find abCardOverlay.js and edit it with a plaintext editor (vim, or WordPad, or…). Notepad is probably a bad choice, and Word is certainly a bad choice.
4. Click the "Diff" link for the patch to see the old and new text in two columns. (Since SeaMonkey is not running, and we don't want to start it, you may want to use another browser to do it: Safari, Konqueror, Opera, Epiphany, Internet Explorer… Hopefully there is one on your machine.)
5. In your editor (opened at step 3) find the "old text" (step 4, left column) and replace it by the "new text" (step 4, right column)
6. "Save and close" (or whatever it is called in that editor) in your editor.
7. Zip the contents of the directory created at step 1 (but not the directory itself) back into omni.ja (overwriting it in your installation directory, where you found it at step 2).
8. Start SeaMonkey again.

Immediately before step 2 you may have to rename omni.ja to omni.zip (depending on the capabilities of your zip/unzip utility); in that case, at step 7 use omni.zip as the zipfile name and rename it to omni.ja thereafter.
P.S. At step 4 you could of course also use Firefox, if you have it installed. ;-)
(In reply to Tony Mechelynck [:tonymec] from comment #32)
> 8. Start SeaMonkey again.

Then the old javascript from old omni.ja will cause the old error. Confusingly you will see the new, changed script in the Source of: jar:... window. 

To get the new script to work, you have to clear a cache. This can be done by (de)installing or (de)activating an AddOn or by starting SeaMonkey with the -purgecaches parameter on the command line.
Hello
thanks for the 2.13.2 that run ok for the addresses in a addressbook with mailing lists.
Sincerly
Thanks to everyone 
and 
a special thanks for 2.13.2 !!!
(<== I believe this is directed to "Justin Wood (:Callek)")

2.13.2 got me back to a secure release--
I'd back-graded to get a release that still worked 
(but "working" and "insecure" is not a longterm solution)

yours in Life,
Michael Carr
Dallas, TX, USA
This bug seems to have reappeared in SM 2.14.1. I am unable to make permanent changes to entries in my address book. This includes deleting contacts, editing contact's information, changing entries in a mailing list and creating a new mailing list. I'm running under Windows XP SP3.
Dick Hoffman
To djhoff:
I initially reported this bug.  I also use WinXP SP3 and am having no further  problems at all with the address book in Seamonkey.  I can edit contacts, add contacts, delete contacts. No problems editing groups either.
Do you use AVG 2013 by chance?
Dick, sorry to hear that you have problems with your address book, but whatever you're seeing, it's not this bug. The cause of this bug had been analyzed, found and fixed months ago. If your problem persists, please open a new bug with clear steps to reproduce. Include information such as used SeaMonkey version and any useful output from the Error Console (to be found under Tools, Web Development). Thanks.
(In reply to Dick Hoffman from comment #38)
> ... I am unable to ... creating a new mailing list. 

Clearly not this bug. As Jens said please watch the Error Console. To get more information there you might want to set the preference dom.report_all_js_exceptions = true
OK, thanks for verifying Bug 801615 is fixed and for the suggestions (I don't see a preference called 'dom.report_all_js_exceptions' but have ALL selected in the Error Console options). On initial revue there are no messages in the Error Console but
I will pursue my problem and may enter a new Bug if I think it merits doing so.
Dick
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: