在学web自动化测试时,通过PO模型将特定页面的一些元素及元素操作放在特定页面模块中, 然后提取公共的部分, 如元素等待WebDriverWait, 元素操作send_keys, click, 获取元素文本信息, 获取属性值等, 放在公共的页面模块里, 即base_page.py,

但在实现过程中我的代码报了错:

想了很久都没发现错在哪里, 那种感觉真不好受...

昨夜西风凋碧树..

衣带渐宽终不悔...

众里寻他千百度....

咦, 那个错误不就在眼皮底下么?

原来是少了一个 return ....

唉,又是一个折磨人的低级错误 !

关于AttributeError: 'NoneType' object has no attribute 'send_keys'的更多相关文章

  1. python3 AttributeError: 'NoneType' object has no attribute 'split'

    from wsgiref.simple_server import make_server def RunServer(environ, start_response): start_response ...

  2. AttributeError: 'NoneType' object has no attribute 'split' 报错处理

    报错场景 social_django 组件对原生 django 的支持较好, 但是因为 在此DRF进行的验证为 JWT 方式 和 django 的验证存在区别, 因此需要进行更改自行支持 JWT 方式 ...

  3. python提示AttributeError: 'NoneType' object has no attribute 'append'【转发】

    在写python脚本时遇到AttributeError: 'NoneType' object has no attribute 'append' a=[] b=[1,2,3,4] a = a.appe ...

  4. AttributeError: 'WebElement' object has no attribute 'send_keys'

    这个是没问题的代码:用来打开谷歌搜索cheese并退出 from selenium import webdriver from selenium.common.exceptions import Ti ...

  5. python提示AttributeError: 'NoneType' object has no attribute 'append'

    在写python脚本时遇到AttributeError: 'NoneType' object has no attribute 'append' a=[] b=[1,2,3,4] a = a.appe ...

  6. Keras AttributeError 'NoneType' object has no attribute '_inbound_nodes'

    问题说明: 首先呢,报这个错误的代码是这行代码: model = Model(inputs=input, outputs=output) 报错: AttributeError 'NoneType' o ...

  7. pyspark AttributeError: 'NoneType' object has no attribute 'setCallSite'

    pyspark: AttributeError: 'NoneType' object has no attribute 'setCallSite' 我草,是pyspark的bug.解决方法: prin ...

  8. AttributeError: 'NoneType' object has no attribute 'extend'

    Python使用中可能遇到的小问题 AttributeError: 'NoneType' object has no attribute 'extend' 或者AttributeError: 'Non ...

  9. 解决opencv:AttributeError: 'NoneType' object has no attribute 'copy'

    情况一: 路径中有中文,更改即可 情况二:可以运行代码,在运行结束时显示 AttributeError: 'NoneType' object has no attribute 'copy' 因为如果是 ...

随机推荐

  1. uni-app微信小程序开发之引入腾讯视频小程序播放插件

    登录微信小程序管理后台添加腾讯视频播放插件: 正式开始使用腾讯视频小程序插件之前需先在微信公众平台 -> 第三方设置 -> 插件管理处添加插件,如下图所示: 在uni-app中引入插件代码 ...

  2. Python3 函数进阶3

    目录 匿名函数 定义匿名函数 匿名函数的使用 内置函数 匿名函数 定义匿名函数 我们之前定义的函数都是有名函数, 我们可以通过函数名来调用 匿名函数顾名思义就是一种没有绑定函数名的函数, 使用一次既被 ...

  3. nginx 自启动设置

    首先,在linux系统的/etc/init.d/目录下创建nginx文件,使用如下命令: 1 vim /etc/init.d/nginx 在脚本中添加如下命令: #!/bin/sh # # nginx ...

  4. JAVA使用SnakeYAML解析与序列化YAML

    1.概述 本文,我们将学习如何使用SnakeYAML库将 YAML文档转换为Java对象,以及JAVA对象如何序列化为YAML文档. 2.项目设置 要在项目中使用SnakeYAML,需要添加Maven ...

  5. 你不知道的JavaScript(上)this和对象原型(二)

    第三章 对象 1.语法 两种形式定义:声明(文字)形式和构造形式 (1)文字语法大概是这样 1 var myObj = { 2 key: value 3 // ... 4 }; (2)构造形式大概是这 ...

  6. eclipse配置svn导出项目

    eclipse安装svn 菜单栏help-->eclipse marketspace-->find中搜索subclipse,安装-->ok windows-->show vie ...

  7. CentOS7.2下部署zabbix4.0

    整体部署采用centos7+php+apache+mariadb 基础环境配置优化 1. 关闭防火墙 [root@monitor_53 ~]$ systemctl stop firewalld [ro ...

  8. vue & nodejs jwt 的基于token身份验证

    现在比较流行的验证方式,是带着token的登录验证 原理 1. 登陆时,客户端发送用户名密码 2. 服务端验证用户名密码是否正确,校验通过就会生成一个有时效的token串,发送给客户端 3. 客户端储 ...

  9. 浅析ketamahash和murmurhash

    说来赶巧,之前我有16个redis集群,然后我要将某个key根据路由规则存到16个集群中的某一个上面,正巧用到了这两种哈希算法,改造完毕上线后,整体带来的效果也十分理想. 说道ketamahash,它 ...

  10. IT兄弟连 HTML5教程 CSS3属性特效 3D变换1

    3D变换较2D变换多了一下的转换属性,3D转换属性及描述如表1: 表1  3D转换属性 3D的转换方法如表2: 表2  3D转换方法     1  transform-style transform- ...