场景:mac 下导入的 ‘select’ 包 import select,然后在 主函数 中创建的 epoll 对象 epl = select.epoll(),运行报错如下

Traceback (most recent call last):
File "tests.py", line , in <module>
emsc.run()
File "tests.py", line , in run
epoll = select.epoll()
AttributeError: module 'select' has no attribute 'epoll'

python官方文档介绍

select.epoll([sizehint=-])
(Only supported on Linux 2.5. and newer.) Returns an edge polling object,
which can be used as Edge or Level Triggered interface for I/O events;
see section Edge and Level Trigger Polling (epoll) Objects below for the methods supported by epolling objects.

答案:仅仅支持Linux2.5.44或更高版本。

参考:

https://blog.csdn.net/weixin_42250835/article/details/89573354

AttributeError: module ‘select’ has no attribute 'epoll’的更多相关文章

  1. AttributeError: module 'select' has no attribute 'epoll'

    AttributeError: module 'select' has no attribute 'epoll'   今天乌班图镜像莫名其妙损坏了,只好用Windows写并发TCP服务器的代码.运行后 ...

  2. Python AttributeError: 'Module' object has no attribute 'STARTF_USESHOWINDOW'

    夫学须志也,才须学也,非学无以广才,非志无以成学.--诸葛亮 生活有度,自得慈铭 --杜锦阳 今天新来的同事安装环境遇到个莫名其妙的问题: AttributeError: 'Module' objec ...

  3. python中引入包的时候报错AttributeError: module 'sys' has no attribute 'setdefaultencoding'解决方法?

    python中引入包的时候报错:import unittestimport smtplibimport timeimport osimport sysimp.reload(sys)sys.setdef ...

  4. Python脚本报错AttributeError: ‘module’ object has no attribute’xxx’解决方法

    最近在编写Python脚本过程中遇到一个问题比较奇怪:Python脚本完全正常没问题,但执行总报错"AttributeError: 'module' object has no attrib ...

  5. attributeError:'module' object has no attribute ** 解决办法

    写了一个小脚本,执行的时候报错: Traceback (most recent call last): File "F:/test/qrcode.py", line 109, in ...

  6. AttributeError: 'module' object has no attribute 'TornadoAsyncNotifier'

    /*************************************************************************** * AttributeError: 'modu ...

  7. AttributeError: 'module' object has no attribute 'Thread'

    $ python thread.py starting at: 2015-08-05 00:24:24Traceback (most recent call last):  File "th ...

  8. AttributeError: module 'enum' has no attribute 'IntFlag'

    Mac PyCharm新建以Python3.6.1为解释器的Django项目的时候出现以下错误提示: AttributeError: module 'enum' has no attribute 'I ...

  9. 【问题解决方案】AttributeError: module 'pygal' has no attribute 'Worldmap'

    <Python编程:从入门到实践>- 16章-16.2.5制作世界地图 import pygal 后报如标题的error 参考CSDN 解决:AttributeError: module ...

随机推荐

  1. Debian 9 / Debian 10 / Ubuntu 18.04 / Ubuntu 18.10快速开启BBR加速 或 关闭BBR加速

    如果使用的是Debian 9.Debian 10.Ubuntu 18.04.Ubuntu 18.10等内核高于4.9版本的系统,均可以使用此方法开启BBR加速,若你使用了Ubuntu 19.04的系统 ...

  2. IDEA忽略编译报错

    设置Intellij IDEA忽略部分类编译错误 File——Settings——Compiler——Java compiler修改:Use complier:将Javac改为Eclipse在Ecli ...

  3. python基础--数据结构之字典

    字典 特点:无序,键唯一 目录 1.字典的创建 2. .setdefault 的使用 3.  字典中的查找 4.字典中的改 5. 字典中的删除 6. 打印字典的方法 7. 格式化字符串 8. 合并字符 ...

  4. 嵌入式Web服务器boa在ARM平台的移植步骤

    1.下载http://www.boa.org/ 2.解压tar xzf boa-0.94.13.tar.gz 3.编译cd boa-0.94.13/src./configure 生成了makefile ...

  5. HTML 图像标签(img)

    一.标签属性 属性就是一个实体的特性,例如:手机的属性有大小,颜色等,HTML标签也有自己的属性. 使用HTML制作网页时,如果想让HTML标签提供更多的信息,可以使用HTML标签的属性加以设置. 语 ...

  6. 【python】一篇文章里的词频统计

    一.环境 1.python3.6 2.windows系统 3.安装第三方模块 pip install wordcloud #词云展示库 pip install jieba #结巴分词 pip inst ...

  7. elasticsearch 连接查询 基于es5.1.1

    ElasticSerch 的连接查询有两种方式实现 nested parent和child关联查询 nested 存储结构 nested的方式和其他字段一样,在同一个type里面存储,以数组的方式存储 ...

  8. Idea中SpringBoot引入thymeleaf没有提示

    问题描述: 最近使用Idea搭建SpringBoot时,用到了 thymeleaf,但是出现了点问题:输入th: 代码有没有提示. 解决方法: <html lang="en" ...

  9. 生成小程序菊花码(生成菊花码、更换中间logo、更改图片尺寸,加文字)

    <?php /** * 获取小程序二维码 */ class getMiniQrcode { public $db = ''; public function __construct() { $t ...

  10. 【Spring Boot】Spring Boot之利用Logstash将日志转换成以JSON的格式存储和输出

    一.Logstash的作用 Logstash是一个完全开源的工具,它可以对日志进行收集.过滤,能非常方便地将日志转换成以JSON的格式存储和输出,并将其存储供以后使用. 二.整合Logstash的步骤 ...