0

I have a Django project with the Python virtual environment installed within the project directory. The directory is ignored by git.

Now I would like to mark the directory as excluded in PyCharm. I can do this with other directories but if I do it with the venv directory, it doesn't work.

It seems as if the process has started. If I try to do it again, I get the option "Cancel Exclusion" (see screenshot). This does not go away and does not resolve itself after longer periods of time (2 hours+).

Any idea what I might be doing wrong or how I can fix this issue?

Screenshot

I am trying to exclude the dir the same way I exclude the static dir.

Screenshot2

Maoristirn
  • 51
  • 6
  • I'm not sure what you're after. `venv` is already marked as excluded by default. – InSync Aug 29 '23 at 09:31
  • Loading the project and reloading the django development server started to take considerably longer without any apparent reason. I tried different stuff. Among them was specifically marking the `venv` directory as excluded. All excluded folders are in "orange" and PyCharm provided me the option to exclude, so I thought this should work. Am I wrong? – Maoristirn Aug 29 '23 at 09:38
  • Do [any](https://stackoverflow.com/q/34976058) [of](https://intellij-support.jetbrains.com/hc/en-us/community/posts/360009461520) [these](https://youtrack.jetbrains.com/issue/PY-53924) work for you? – InSync Aug 29 '23 at 09:42
  • @InSync Thank you. I already updated to the last version and had reinstalled my system python interpreter and also this venv. Invalidating the Cache did the trick for me, the indexing is now faster again. The described effect (not able to mark as excluded) still persists, though. – Maoristirn Aug 29 '23 at 13:22

0 Answers0