OError: [Errno 26] Text file busy: '/…myvirtualenv/bin/python'

前端 未结 2 813
再見小時候
再見小時候 2021-01-07 20:33

I try to recreate the virtualenv:

foo_bar_d@aptguettler:~$ virtualenv --system-site-packages . 

I get this exception:

foo_b         


        
相关标签:
2条回答
  • 2021-01-07 21:00

    I had the exact same problem :)

    virtualenv works (afaik) by modifying a copy of the python executable in the virtualenv directory area.

    You must have a process using the virtualenv already so the copy of the python executable is 'in use' (technically it's mmap()'ed into memory whilst it's executing).

    Unless you need to change the setup of a virtualenv you don't need to re-run the virtualenv command every time - once it's setup you just activate it when needed.

    As to why it happens - It's possible that you have a service running at boot time:

    ps -ef | grep python
    
    0 讨论(0)
  • 2021-01-07 21:01

    Kill Python Processes running on your system with pkill python

    I will work

    0 讨论(0)
提交回复
热议问题