推荐学习书目
› 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
TobiahShaw
V2EX  ›  Python

jupyter notebook 运行某些命令行交互的代码如何响应

  •  
  •   TobiahShaw · May 31, 2019 · 4368 views
    This topic created in 2695 days ago, the information mentioned may be changed or developed.
    比如说我需要调用一个下载数据的函数,但是这个函数会在命令行询问是否下载,需要输入 Y/n,在 jupyter 中直接就 EOF 异常了,我也尝试去往缓冲区写东西,但是方法并没有响应,是否有魔法命令解决这个问题呢
    3 replies  •  2019-05-31 16:27:14 +08:00
    TimePPT
        1
    TimePPT  
       May 31, 2019
    jupyter 理论上是支持 shell 交互的啊,贴下代码吧
    TobiahShaw
        2
    TobiahShaw  
    OP
       May 31, 2019
    @TimePPT 不好意思,刷新了一下,又运行了一遍可以了,可能是我 jupyter 不是跑在本地的,有些 js 没加载上,谢谢了
    TimePPT
        3
    TimePPT  
       May 31, 2019
    @TobiahShaw 了解,没事
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   920 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 20:39 · PVG 04:39 · LAX 13:39 · JFK 16:39
    ♥ Do have faith in what you're doing.