吾爱破解 - LCG - LSG |安卓破解|病毒分析|www.52pojie.cn

 找回密码
 注册[Register]

QQ登录

只需一步,快速开始

查看: 386|回复: 2
收起左侧

[已解决] UnboundLocalError: cannot access local variable 'salary' where it is not asso...

[复制链接]
Zzxy 发表于 2024-3-16 13:29
在chrome爬取boss直聘时出现“UnboundLocalError: cannot access local variable 'salary' where it is not associated with a value”错误
我的代码 image.png
错误提示
image.png

发帖前要善用论坛搜索功能,那里可能会有你要找的答案或者已经有人发布过相同内容了,请勿重复发帖。

我心飞翔1995 发表于 2024-3-16 16:34
你的选择分支导致salary没有定义就跳到print了,先全局定义一个salary,赋个初始值
 楼主| Zzxy 发表于 2024-3-16 18:24
我心飞翔1995 发表于 2024-3-16 16:34
你的选择分支导致salary没有定义就跳到print了,先全局定义一个salary,赋个初始值

好的,谢谢,解决了
您需要登录后才可以回帖 登录 | 注册[Register]

本版积分规则 警告:本版块禁止回复与主题无关非技术内容,违者重罚!

快速回复 收藏帖子 返回列表 搜索

RSS订阅|小黑屋|处罚记录|联系我们|吾爱破解 - LCG - LSG ( 京ICP备16042023号 | 京公网安备 11010502030087号 )

GMT+8, 2024-5-1 19:13

Powered by Discuz!

Copyright © 2001-2020, Tencent Cloud.

快速回复 返回顶部 返回列表