You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed the postCreateCommand in your solution always deletes the existing .venv and creates a new one, which will result in reinstalling dependencies every time. This could slow down the setup process unnecessarily.
I recommend using this alternative approach:
"postCreateCommand": "[ -d .venv ] || make venv && . .venv/bin/activate && make install"
This checks if the .venv directory already exists and reuses it if available. If it doesn’t exist, it will create the virtual environment and install dependencies.
This way, we avoid recreating the virtual environment every time, which should help save time, especially when dependencies are already in place. What do you think?
One thing I'm wondering though: Can anyone think of a way that keeps the contents of venv synchronized with the current state of the repo? Because the check for the existence of a .venv dir is easy to satisfy, but it does not ensure that .venv actually contains what it should contain.
update
.devcontainer.json
:The text was updated successfully, but these errors were encountered: