Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #76009

Re: why i can't copy mail with imaplib?

Date 2014-08-10 16:27 -0700
From luofeiyu <elearn2014@gmail.com>
Subject Re: why i can't copy mail with imaplib?
References <mailman.12821.1407690877.18130.python-list@python.org> <ls8tvu$h5d$1@reader1.panix.com>
Newsgroups comp.lang.python
Message-ID <mailman.12830.1407713290.18130.python-list@python.org> (permalink)

Show all headers | View raw


 >>> x.con.list()
('OK', [b'(\\HasNoChildren) "/" "INBOX"', b'(\\Noselect \\HasChildren) 
"/" "[Gma
il]"', b'(\\HasNoChildren \\Junk) "/" "[Gmail]/&V4NXPpCuTvY-"', 
b'(\\HasNoChildr
en \\Trash) "/" "[Gmail]/&XfJSIJZkkK5O9g-"', b'(\\HasNoChildren 
\\Flagged) "/" "
[Gmail]/&XfJSoGYfaAc-"', b'(\\HasNoChildren \\Sent) "/" 
"[Gmail]/&XfJT0ZCuTvY-"'
, b'(\\HasNoChildren \\All) "/" "[Gmail]/&YkBnCZCuTvY-"', 
b'(\\HasNoChildren \\D
rafts) "/" "[Gmail]/&g0l6Pw-"', b'(\\HasNoChildren \\Important) "/" 
"[Gmail]/&kc
2JgQ-"'])
 >>> x.con.select("inbox")
('OK', [b'40'])
 >>> x.con.copy(b"1","[Gmail]/&kc2JgQ-]")
('NO', [b'[TRYCREATE] No folder [Gmail]/\xe9\x87\x8d\xe8\xa6\x81] 
(Failure)'])
 >>> x.con.copy(b"1","[Gmail]/Important")
('NO', [b'[TRYCREATE] No folder [Gmail]/Important (Failure)'])
On 8/10/2014 4:07 PM, John Gordon wrote:
> In <mailman.12821.1407690877.18130.python-list@python.org> luofeiyu <elearn2014@gmail.com> writes:
>
>> self.con.select("inbox")
>> self.con.copy(b"1","[Gmail]/&kc2JgQ-]")
>> why i can not copy the first email into my  important mailbox?
> What happens when you run the above code?  Do you get an error?
>

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

why i can't copy mail with imaplib? luofeiyu <elearn2014@gmail.com> - 2014-08-10 06:44 -0700
  Re: why i can't copy mail with imaplib? John Gordon <gordon@panix.com> - 2014-08-10 23:07 +0000
    Re: why i can't copy mail with imaplib? luofeiyu <elearn2014@gmail.com> - 2014-08-10 16:27 -0700
    Re: why i can't copy mail with imaplib? Ben Finney <ben+python@benfinney.id.au> - 2014-08-11 09:32 +1000

csiph-web