解决 “OSError: [Errno 1] Operation not permitted” when installing Scrapy in OSX 10.11 (El Capitan) (System Integrity Protection)

“OSError: [Errno 1] Operation not permitted” when installing Scrapy in OSX 10.11 (El Capitan) (System Integrity Protection)

这是由于苹果新系统的安全检查策略导致的

由于El Capitan引入了SIP机制(System Integrity Protection),默认下系统启用SIP系统完整性保护机制,无论是对于硬盘还是运行时的进程限制对系统目录的写操作。

  • 方案(一):

    • 禁用掉苹果SIP系统,按住WIN+R重启电脑,按住Command+R(直到出现苹果标志)进入Recovery Mode(恢复模式)左上角菜单里找到实用工具 -> 终端
      输入csrutil disable回车
    • 不过强烈不建议这种方法来修改,这种解除底层级别的禁止虽然会给你带来更大的自用,同时带来系统的不稳定性,和不安全性。所以最好不要这么做。
  • 方案(二):

  • brew install python
    
    
  • 方案(三):

    • pip install --ignore-installed six
      通过pip 增加的功能绕过限制
      

posted @ 2017-08-01 15:30  MaxProAim  阅读(265)  评论(0编辑  收藏  举报