devenv: Devenv slows down with big code repositories

Describe the bug

When you have a big project and maybe some cache like 10 GB it gets really slowed down by git commands. Maybe that command can be ignored?

 |   \-+= 25589 root /usr/bin/login -fpl shyim /Applications/iTerm.app/Contents/MacOS/ShellLauncher --launch_shell
 |     \-+= 25590 shyim -zsh
 |       \-+- 25994 shyim -zsh
 |         \-+- 25995 shyim /usr/local/bin/direnv export zsh
 |           \-+- 25996 shyim /bin/bash -c eval "$("/usr/local/bin/direnv" stdlib)" && __main__ source_env $'/Users/shyim/Code/shopware/cloud/.envrc'
 |             \-+- 26011 shyim /bin/bash -c eval "$("/usr/local/bin/direnv" stdlib)" && __main__ source_env $'/Users/shyim/Code/shopware/cloud/.envrc'
 |               \-+- 26012 shyim bash /Users/shyim/.nix-profile/bin/devenv print-dev-env
 |                 \-+- 26021 shyim /nix/store/ynwgbyq3p1db8wg5hw8b192l3336g65b-nix-2.12.0pre20221221_51b770e/bin/nix --show-trace --extra-experimental-features nix-command --extra-experimental-features flakes print-dev-env --impure
 |                   \--- 26027 shyim git -C /Users/shyim/Code/shopware/cloud --git-dir .git ls-files --cached -z --others

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Reactions: 9
  • Comments: 24 (22 by maintainers)

Most upvoted comments

devenv already includes this PR, but it’s still slow (not minutes as it was before, but now in seconds).

Oh cool ! Do you think it will get merged upstream anytime soon ? Has it been working fine in devenv until now ?

I hope it will be merged soon, it has been working more or less fine 😃

I know what to fix there, needs a few hours of work. Making it high priority 😃

This has been fixed in 1.3! More work will follow as part of #1548

Is there something nice to debug what is slow at devenv up. We have here an M1 Pro with 32GB of memory it takes 3 minutes to start it. It takes like a minute until it shows something and then two times resolving something

Maybe an idea to have an --debug flag, which shows any command executed and the duration in the shell?

I can’t test it at Home, somehow the python cannot be built on my machine. It just hangs forever configure. I will try it at work tomorrow, maybe that helps.

devenv already includes this PR, but it’s still slow (not minutes as it was before, but now in seconds).