Offline: Dragging multiple messages from an IMAP server folder to a local folder fails, can't move/copy into that folder again until restart

VERIFIED FIXED in mozilla1.0

Status

VERIFIED FIXED
17 years ago
14 years ago

People

(Reporter: jquinn, Assigned: Bienvenu)

Tracking

Trunk
mozilla1.0
x86
Windows XP

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [ADT2])

Attachments

(2 attachments)

(Reporter)

Description

17 years ago
I have an IMAP account. I create a new local folder. I select multiple messages
on my server inbox. I drag them to the local folder. Nothing happens. From then
on, I can never drag any messages into the local folder that were not there already.

In the .msf for the folder after it's corrupted, I note the following final
paragraph added vis a vis the pre-corrupted state:

@$${2{@
< <(a=c)> // (f=iso-8859-1)
  (AF=sortType)(B0=sortOrder)(B1=viewFlags)(B2=viewType)>
<(85=12)>[-1:^9E(^AD=1)(^A8=ro)(^88=4)(^A4=0)(^A6^84)(^AF=12)(^B0=1)
    (^B1=0)(^B2=0)]
@$$}2}@

Comment 1

17 years ago
not movemail, assigning to naving
Assignee: adam → naving
Component: Movemail → Mail Back End
QA Contact: esther → sheelar
(Reporter)

Comment 2

17 years ago
(while working offline)

Updated

17 years ago
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: nsbeta1
Summary: Dragging multiple messages from an IMAP server folder to a local folder fails, local folder then corrupt → Offline: Dragging multiple messages from an IMAP server folder to a local folder fails, local folder then corrupt

Comment 3

17 years ago
over to bienvenu who does offline
Assignee: naving → bienvenu
Component: Mail Back End → Offline
QA Contact: sheelar → gchan

Comment 4

17 years ago
Hmm. Reporter can you give steps to reproduce and build id?

Using 2002032803 on NT 4.0 I am seeing something.

My steps:
1.Login to imap mail acnt
2.create a folder under Local Folders
2.download few mesgs from your imap mail acnt
3.go offline but don't download entire folder
4.Try to move/drag/copy few mesgs (downloaded/not downloaded)
result: doesn't work. It appears to work (no error mesg or anything)
        but when you go to that folder, it's empty.

        if you go back online and try to move/drag/copy to that same folder
        it also fails.

expected: mesgs to be copied/moved over to that folder.

So bascically when you try to move a mesg (while offline) to
a folder under Local Folders it corrupts that folder and you are
unable to copy/move anything to that folder while on/offline.

If I try the same steps between 2 imap accnts, it works (at least
copy/move while offline) but get strange results when you go online
(see bug 123721)



David, there are similar bugs out there (none filed on Local Folders)
  bug 78809 -Offline copy of an imap message moved offline is lost 
            when going  back online
  bug 123721 -Offline move/copy across imap servers fails 


              

(Assignee)

Comment 5

17 years ago
Hey, an Obie! 
Can you move/copy messages into the new local folder after you shut down and
restart?
(Assignee)

Comment 6

17 years ago
changing summary, there's no corruption that I see. Once you shutdown and
restart, you can copy messages into that folder. What's happening is that the
offline move/copy is starting but never finishing, so we think that we can't
move/copy any more messags into the destination folder, because we think we're
already in the middle of a move/copy into that folder. I'm pretty sure this is a
regression.
Status: NEW → ASSIGNED
Keywords: regression
Summary: Offline: Dragging multiple messages from an IMAP server folder to a local folder fails, local folder then corrupt → Offline: Dragging multiple messages from an IMAP server folder to a local folder fails, can't move/copy into that folder again until restart
(Assignee)

Comment 7

17 years ago
Gary, is it possible that this never worked? I find that hard to believe, but
I'm having trouble finding where this might have regressed.
Keywords: regression

Comment 8

17 years ago
Ok David, I think you are right. Looks like the problem has
been here for awhile. This is going to be a doozy of a writeup.
I'm thinking like 4 bugs out of this one...

Tested final 6.2 commercial rtm builds on Linux/Mac 10.1.3
and this is what i found out:
 while offline:
   -if you move one downloaded mesg at a time from your inbox/any online folder
    to a folder on local folders it works. But when you go online
    the mesgs you moved reappear back in their original folder
    (which I assume is bug 78809, please correct me if I'm wrong)
    The local folder still contains the 'copy' of the mesgs you moved
    as it's not emptied when you go back online.
    But once online you can move down/non-down mesgs to Local folder
    w/no problems
   -if you move a non-downloaded mesg or move 2 or more downloaded mesgs
    to a folder under Local folders, it doesn't work. the move fails
    and you are now unable to move or copy any mesg (down/non-down)
    to folder under Local Folders on/offline. Once you exit/restart, you can
    then do any move/copies to folder under Local Folders fine.

Using 2002032803 on NT 4.0 and linux 2.2
  -Online
    -move a mesg from Local Folders  to online Imap mail act it fails
     See this error mesg: 'The current command did not succeed. The
                           mail server responded: Mesg contains invalid
                           header'
     This is implying to me move mesgs is broken as this worked in 6.2
     rtm builds. And maybe affecting offline move mesgs?
     No problem moving a mesg from Inbox to Local folders though.
  -Offline
    -if you move one downloaded mesg at a time from your inbox/any online folder
     to a folder on local folders it works. But Here is where it's different
     than 6.2 rtm When I go online, the mesg I moved from my inbox does NOT
     reappear back in the inbox. 
    -if you move a non-downloaded mesg or move 2 or more downloaded mesgs
     to a folder under Local folders, it doesn't work. the move fails
     and you are now unable to move or copy any mesg (down/non-down)
     to folder under Local Folders on/offline. Once you exit/restart, you can
     then do any move/copies to folder under Local Folders fine.
     Just like behavior in 6.2

Whew. I hope this is clear enough David. Let me know if you want
me to file off new bugs on any of this stuff..

Comment 9

17 years ago
Mail News team needs to know if comment #4, step 2 (2.create a folder under
Local Folders)is REQUIRED to reproduce this bug.
Whiteboard: needinfo
(Assignee)

Comment 10

17 years ago
No, all that has to happen is you move/copy messages from an imap folder to a
local folder, any local folder, while offline.  This bug needs to be fixed, I
believe. 

Comment 11

17 years ago
Adding info for ADT:
 Using commercial trunk 2002040203 on nt 4.0

 ADT wanted to know if this bug exists only for newly created
 folders under Local Account? The answer is no. I tried
 moving non-downloaded mesg, while offline, to the sent folder
 and it failed. When I went back online and tried to move
 a mesg it failed. When I quit/restart it's fine.

Comment 12

17 years ago
More info for this bug:
 -If set my mail prefs for 'sent folder' to be under local folders
 -go offline
 -compose a mesg and do 'send later'
 -move a non-downloaded mesg from my imap mail folder to
  the sent folder under local folders
 -it obviously doesn't get moved over
 -go online and send mail at the prompt
  error message appears: "the message was sent successfully but 
         could not be copied to sent folder. Please verify that your
         Mail&Newsgroup account settings are correct and try again"
 -I try to compose another mesg, after going back online, and the
  new mesg is successfully copied to the sent folder under Local Folders.
 -I try to move a mesg (down/non-downloaded) to sent folder under Local
  Folders and that works now.


Comment 13

17 years ago
Discussed in Mail News bug meeting.  Decided to ADT2 and plus this bug.  Also
removing my needinfo which was kindly supplied by bienvenu.
Keywords: nsbeta1 → nsbeta1+
Whiteboard: needinfo → [ADT2]
Target Milestone: --- → mozilla1.0
(Assignee)

Comment 14

17 years ago
Gary, re this comment" move a mesg from Local Folders  to online Imap mail act
it fails with this error: 'The current command did not succeed. The            
          mail server responded: Mesg contains invalid header'"

This is probably specific to the message you tried to move. Our imap server is
very picky about the messages that it allows to get appended to an imap folder,
so if any header is mal-formed, it will complain. Does this happen for every
message you try to copy to the imap server, or just some messages? How did these
local messages get created. It can be tricky to create test messages and copy
them up to the imap server.

Comment 15

17 years ago
I guess you're right David. Tried it w/2002040403 commercial trunk
on NT 4.0 and it seems to work. I was trying to move
some of mesgs stored on the Sent folder under Local folders
to a online Imap folder (mesg server 4.15). I tried moving
few mesgs and it worked. I found one that didn't. When comparing
2 mesgs (one that worked/one that didn't) I think it is because
the Mesg that failed was originally a 4.x sent mesg that I think
was stored in unsent mesgs folder. So i migrated it over, did a
send unsent mesg and it got copied under Local Folders act. So when
i try to move it that's why it complained.

That particular mesg has this additional header:
 X-Mailer: Mozilla 4.79[en](WinNT:U]

Thanks. sorry for the alarm.

(Assignee)

Comment 16

17 years ago
The way this worked in 4.x is that if any of the messages weren't downloaded for
offline use, we put up an error message that the messages should be downloaded
for offline use first; otherwise, we went ahead and did the move/copy. I think
that's the way I'm going to go with this bug, since otherwise, you end up with
local folders that don't have the moved/copied messages while offline, and it
can be confusing for users.
(Assignee)

Comment 17

17 years ago
Created attachment 79289 [details] [diff] [review]
proposed fix

two parts to this fix - the first part is to make sure we have offline msg
bodies for all the messages we're trying to move/copy; if not, we put up an
error message. The second part is to copy the messages one at a time if we're
copying offline imap messages.
(Assignee)

Comment 18

17 years ago
Navin, can I get a review? thx.

Comment 19

17 years ago
Comment on attachment 79289 [details] [diff] [review]
proposed fix

r=naving

aMessage should be message and why is this

PRBool hasMsgOffline initialized to PR_TRUE ?
Attachment #79289 - Flags: review+
Comment on attachment 79289 [details] [diff] [review]
proposed fix

1) any reason not switch uri to a nsXPIDLCString and protocolType to a
nsCAutoString

2) can you get buy off on the new string from robinf?

If you want to land on the branch, since is late in the game, you need approval
from the i18n team, also.

sr=sspitzer
Attachment #79289 - Flags: review+ → superreview+
(Assignee)

Comment 21

17 years ago
Created attachment 79293 [details] [diff] [review]
patch for just nsLocalMailFolder.cpp incorporating comments
(Assignee)

Comment 22

17 years ago
Robin, can you review the text of the error message I'm adding? Here's the text:
"Cannot move/copy message(s) not downloaded for offline use to local folders
while offline. Select Go Online from the File menu, then try again."
This message is displayed when the user tries to move/copy news or imap messages
that have not been downloaded for offline use to a local folder , while offline.

I'm sure this won't be in the beta or moz 1.0. It's up to the adt whether or not
it's in the Netscape release.

Comment 23

17 years ago
Comment on attachment 79293 [details] [diff] [review]
patch for just nsLocalMailFolder.cpp incorporating comments

r=naving
Attachment #79293 - Flags: review+

Comment 24

17 years ago
Suggested text: "While working offline, you cannot move or copy messages that
were not downloaded for offline use. From the Mail window, open the File menu,
choose Offline, then choose Work Online, and then try again."
(Reporter)

Comment 25

17 years ago
I'm the guy who posted this bug, and I (as a relativelty clueful computer user)
would have no idea what the second half of robinf's suggested text meant.
(Assignee)

Comment 26

17 years ago
fixed on trunk.
Status: ASSIGNED → RESOLVED
Last Resolved: 17 years ago
Resolution: --- → FIXED

Comment 27

17 years ago
jquinn, the second sentence of the suggested error message - "From the Mail
window, open the File menu, choose Offline, then choose Work Online, and then
try again." - describes the exact steps from the Mail window for choosing the
menu item that will allow the user to go online. I agree that it's awkward, but
that's in fact where users will find the "Work Online" menu item. Alternatively,
for the second sentence, we could say "From the Mail window, click the Work
Online icon located in the bottom right corner of the window, and then try again."
(Reporter)

Comment 28

17 years ago
Ok, I get it now, I was confused by the word "choose" as in "choose offline",
that to me indicates a final choice, I don't know about standard mozilla
terminology or anything but I'd far far prefer something like "look under __" or
"open the __ submenu".
(Reporter)

Comment 29

17 years ago
(Sorry for all my newbieness but...) Target milestone is 1.0, RESOLVED/FIXED for
over a month, but my recently downloaded 1.0 RC2 candidate (2002051506) still
has this bug. Is this a mixup? (If not, when does this fix make it into 1.0? And
how do I tell whether it has?)
(Assignee)

Comment 30

17 years ago
right, rc1 and rc2 are built off the mozilla 1.0 branch - this fix is only in
the trunk, and will most likely not be in the mozilla 1.0 release. It will be in
Mozilla 1.1, however, and all the daily trunk builds

Comment 31

17 years ago
making nsbeta1- for rtm.
Keywords: nsbeta1+ → nsbeta1-

Comment 32

17 years ago
Using commercial trunk:
2002-05-29-08-trunk/ nt 4.0, linux 2.2, mac 10.1.4
2002-05-29-11-trunk/  mac 9.2.2

Verified the following:
 -can't move/copy/drag&drop any non-downloaded mesgs from imap folders to 
  any folder under Local Folders while offline
 -Error mesg will appear if you move/copy/drag&drop any non-downloaded 
  mesg from imap folder to a folder under Local Folders
 -Error mesg is exactly as stated in comment 24
 -if you go back online, you can move/copy/drag&drop any non-downloaded 
  or downloaded mesg to Local Folders with no problem
 -while offline, you can move/copy/drag&drop any downloaded mesg
  to folder under Local Folders with no problem
 -while offline, if you try to move/copy/drag&drop a downloaded & non-downloaded
  mesg to folder under Local folders it wil fail and you will see the 
  error mesg
 -while offline, you can move more/copy/drag&drop more than one downloaded
  mesg at a time to Local folders with no problems.


Note the only minor thing I saw was, while offline, if I did drag&drop
of non-downloaded mesg to folder under Local Folders, the error mesg
took maybe a second or two to display on screen. Initially it was
blank but eventually you saw the error mesg. Did not see this delay
when doing a file menu or context menu of 'copy' or 'move'. This only
applies to drag&drop.

marking as verified.


Status: RESOLVED → VERIFIED
(Reporter)

Comment 33

17 years ago
(Yes this bug is fixed. But of course not mentioned is that all the mail dragged
out of the online folder into the offline folder then reappears as per <a
href="http://bugzilla.mozilla.org/show_bug.cgi?id=67172">bug 67172</a>)

Comment 34

17 years ago
using 2002052908 commercial branch on nt 4.0,
when i move/drag&drop a downloaded mesg from my imap folder to a
local folder, while offline, when I go back online
the mesg does NOT reappear in my imap folder.
Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.