小编dra*_*jin的帖子

如何在窗口ubuntu bash中安装python3.6

我在Window 10 build 15002上使用ubuntu 16.04窗口bash我想在我的窗口10 bash中使用python3.6.然后我安装了python3.6 tar球.

我在安装时按照README文件进行设置,

$ ./configure; make; make test; sudo make install;
Run Code Online (Sandbox Code Playgroud)

但是,安装时出现错误.以下是"./confiugure"

?  Python-3.6.0 ./configure
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking for python3.6... python3.6
checking for --enable-universalsdk... no
checking for --with-universal-archs... no
checking MACHDEP... linux
checking for --without-gcc... no
checking for --with-icc... no
checking for gcc... gcc
checking whether the C compiler works... no
configure: error: in `/usr/local/develop/language/Python-3.6.0':
configure: error: C compiler cannot create executables
See `config.log' for more details …
Run Code Online (Sandbox Code Playgroud)

python linux gcc python-3.6 windows-subsystem-for-linux

14
推荐指数
2
解决办法
1万
查看次数

在 Python 3.4.3 中,如何使用 IMAP 协议发送标志“Seen”

  1. 获取标记为“UNSEEN”的邮件列表
  2. 阅读每封邮件
  3. 留下一个标记“已看到”,这是我制作的。

我想在我的电子邮件帐户中设置邮件标记“已查看”。我如何在 python 中设置“Seen”标志。

你有什么主意吗?

import imaplib

emailConnection = imaplib.IMAP4_SSL() 
emailConnection.login(id, password)

emailConnection.select(configData['email_input_folder']) 

result, data = emailConnection.uid('SEARCH', None, '(UNSEEN)')
uids = data[0].split()
for uid in uids:
    result, data = emailConnection.uid('fetch', uid, '(RFC822)') 
    # ------   data is manufactured.
    result = emailConnection.store(uid, '+FLAGS', '\\Seen')  # << Occured Exception
Run Code Online (Sandbox Code Playgroud)

在我的错误消息中打印如下。

[DEBUG|imap.py:81]2017-02-24 21:43:57,921 > STORE command error: BAD [b'Error in IMAP command STORE: Invalid messageset'] 
Run Code Online (Sandbox Code Playgroud)

email imap python-3.x

5
推荐指数
1
解决办法
2660
查看次数