V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
jj123456
V2EX  ›  Python

python3 的错误是什么情况

  •  
  •   jj123456 · 2018-03-05 15:32:18 +08:00 · 3192 次点击
    这是一个创建于 2236 天前的主题,其中的信息可能已经有所发展或是发生改变。

    求问下面的 python 错误是因为什么原因,python3 使用 brew 安装的

    /usr/local/Cellar/python/3.6.4_3/Frameworks/Python.framework/Versions/3.6/Resources/Python.app/Contents/MacOS/Python: can't open file 'run': [Errno 2] No such file or directory
    
    10 条回复    2018-03-05 21:08:49 +08:00
    snowolfy
        1
    snowolfy  
       2018-03-05 15:51:19 +08:00
    说是没有找到 `run` 这个文件?
    likuku
        2
    likuku  
       2018-03-05 16:35:34 +08:00
    用 pyenv,再重复多少次也是不够的。

    pyenv 入门介绍 - V2EX : https://www.v2ex.com/t/420216
    julyclyde
        3
    julyclyde  
       2018-03-05 17:28:13 +08:00
    @likuku 你这答案并没有针对 lz 的提问啊
    xsseroot
        4
    xsseroot  
       2018-03-05 17:30:39 +08:00
    楼主你不贴下上下文说明情况?怎么给你看啊
    jj123456
        5
    jj123456  
    OP
       2018-03-05 17:45:20 +08:00
    使用的命令是
    ```
    python3 run server.py
    ```
    就出现了这个问题
    @xsseroot
    xwyam
        6
    xwyam  
       2018-03-05 17:49:26 +08:00 via Android   ❤️ 2
    @jj123456 python3 server.py 应该就可以了
    xsseroot
        7
    xsseroot  
       2018-03-05 17:59:25 +08:00
    @xwyam +1
    beforeuwait
        8
    beforeuwait  
       2018-03-05 18:02:09 +08:00
    6 楼 +1
    omph
        9
    omph  
       2018-03-05 18:16:29 +08:00
    python3 server.py run
    IanPeverell
        10
    IanPeverell  
       2018-03-05 21:08:49 +08:00
    python3 命令的格式是 python3 文件名.py arg1 arg2 …… 所以至少也是#9 的样子
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   5295 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 26ms · UTC 05:51 · PVG 13:51 · LAX 22:51 · JFK 01:51
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.