python - 第 21 行,在os.startfile(fileName) AttributeError: 模块 'os' 没有属性 'startfile'
问题描述
第 21 行,在 os.startfile(fileName) AttributeError: module 'os' has no attribute 'startfile'
在 Mac 上,每次发生这种情况
解决方案
就像文档明确指出的那样,os.startfile()
仅适用于 Windows。
推荐阅读
- java - 如何读取大文件以分块并处理它
- gradle - Gradle Liquibase 集成
- angular - LocalNotification - 如何使用它?
- ruby-on-rails - 在 Rails 中为 form_tag 添加命名空间
- networking - 创建和发送自定义数据包的最佳方式
- amazon-elb - AWS ALB 返回 502 并且请求未达到目标
- c# - 新版 Nswag 生成不兼容的数据类型
- mongodb - 重命名 MongoDB 4.0.4 数据库名称
- angular - Mapbox not works global 未定义
- javascript - 调整 Internet 窗口浏览器大小时,有没有办法保留 OpenStreetMap 背景图像?