When I run django in localhost via runserver I see that .py files are compiled to .pyc.
When I deploy everything to server using apache and mod_wsgi – should www user has write access to folders with my application? So it will be able to create .pyc
Of course, having write access is not a good idea – if I remove it, will ti slow down app; or compiled python code is cached in memory?
thanks
.pycfiles are only used as bytecode cache between invocations of the interpreter; Python will use them if present but has no problem with recompiling the code instead. So to answer your question, you do not need to give the WSGI application write access to the source location.