Thanks for the reply. Then something is wrong with my setup. Even without changing anything a run of sage -b takes more than 4 min for me. I'd now run multiple builds `sage -b` directly without any changes in between and all apps closed etc. The output is attached below. Maybe the reason is that I'm using WSL 2 on Windows?
Regardless of these problems (which are apparently specific to my situation), don't you think it would be worthwhile to extract the library part of sage? I think this would reduce the overhead needed to develop code for sage. Best Tobias tobias@DESKTOP-OMSMBL2:/mnt/d/Programming/Projects/sage$ ./sage -b cd . && export \ SAGE_ROOT=/doesnotexist \ SAGE_SRC=/doesnotexist \ SAGE_SRC_ROOT=/doesnotexist \ SAGE_DOC_SRC=/doesnotexist \ SAGE_BUILD_DIR=/doesnotexist \ SAGE_PKGS=/mnt/d/Programming/Projects/sage/build/pkgs \ && sage-python -u setup.py --no-user-cfg build install /mnt/d/Programming/Projects/sage/src/bin/sage-env: line 130: cd: /doesnotexist: No such file or directory Warning: overwriting SAGE_ROOT environment variable: Old SAGE_ROOT=/doesnotexist New SAGE_ROOT= Discovering Python/Cython source code.... Discovered Python/Cython sources, time: 1.53 seconds. running build Generating auto-generated sources Building interpreters for fast_callable running build_cython Enabling Cython debugging support Updating Cython code.... Finished Cythonizing, time: 76.81 seconds. running build_py running build_ext Executing 0 commands (using 1 thread) Time to execute 0 commands: 0.24 seconds. Total time spent compiling C/C++ extensions: 31.99 seconds. running install running install_lib byte-compiling /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages/sage/ext_data/nbconvert/postprocess.py to postprocess.cpython-37.pyc running install_egg_info Removing /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages/sage-9.1-py3.7.egg-info Writing /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages/sage-9.1-py3.7.egg-info Cleaning up stale installed files.... - cleaning /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages Cleaning up stale file: /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages/sage/ext_data/nbconvert/__pycache__/postprocess.cpython-37.pyc - cleaning build/lib.linux-x86_64-3.7 Finished cleaning, time: 15.45 seconds. if [ "$UNAME" = "CYGWIN" ]; then \ sage-rebase.sh "$SAGE_LOCAL" 2>/dev/null; \ fi real 6m1.625s user 0m23.031s sys 1m1.448s tobias@DESKTOP-OMSMBL2:/mnt/d/Programming/Projects/sage$ ./sage -b cd . && export \ SAGE_ROOT=/doesnotexist \ SAGE_SRC=/doesnotexist \ SAGE_SRC_ROOT=/doesnotexist \ SAGE_DOC_SRC=/doesnotexist \ SAGE_BUILD_DIR=/doesnotexist \ SAGE_PKGS=/mnt/d/Programming/Projects/sage/build/pkgs \ && sage-python -u setup.py --no-user-cfg build install /mnt/d/Programming/Projects/sage/src/bin/sage-env: line 130: cd: /doesnotexist: No such file or directory Warning: overwriting SAGE_ROOT environment variable: Old SAGE_ROOT=/doesnotexist New SAGE_ROOT= Discovering Python/Cython source code.... Discovered Python/Cython sources, time: 0.90 seconds. running build Generating auto-generated sources Building interpreters for fast_callable running build_cython Enabling Cython debugging support Updating Cython code.... Finished Cythonizing, time: 50.40 seconds. running build_py running build_ext Executing 0 commands (using 1 thread) Time to execute 0 commands: 0.21 seconds. Total time spent compiling C/C++ extensions: 21.32 seconds. running install running install_lib byte-compiling /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages/sage/ext_data/nbconvert/postprocess.py to postprocess.cpython-37.pyc running install_egg_info Removing /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages/sage-9.1-py3.7.egg-info Writing /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages/sage-9.1-py3.7.egg-info Cleaning up stale installed files.... - cleaning /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages Cleaning up stale file: /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages/sage/ext_data/nbconvert/__pycache__/postprocess.cpython-37.pyc - cleaning build/lib.linux-x86_64-3.7 Finished cleaning, time: 15.17 seconds. if [ "$UNAME" = "CYGWIN" ]; then \ sage-rebase.sh "$SAGE_LOCAL" 2>/dev/null; \ fi real 4m27.670s user 0m24.173s sys 0m36.523s tobias@DESKTOP-OMSMBL2:/mnt/d/Programming/Projects/sage$ ./sage -b cd . && export \ SAGE_ROOT=/doesnotexist \ SAGE_SRC=/doesnotexist \ SAGE_SRC_ROOT=/doesnotexist \ SAGE_DOC_SRC=/doesnotexist \ SAGE_BUILD_DIR=/doesnotexist \ SAGE_PKGS=/mnt/d/Programming/Projects/sage/build/pkgs \ && sage-python -u setup.py --no-user-cfg build install /mnt/d/Programming/Projects/sage/src/bin/sage-env: line 130: cd: /doesnotexist: No such file or directory Warning: overwriting SAGE_ROOT environment variable: Old SAGE_ROOT=/doesnotexist New SAGE_ROOT= Discovering Python/Cython source code.... Discovered Python/Cython sources, time: 0.91 seconds. running build Generating auto-generated sources Building interpreters for fast_callable running build_cython Enabling Cython debugging support Updating Cython code.... Finished Cythonizing, time: 50.39 seconds. running build_py running build_ext Executing 0 commands (using 1 thread) Time to execute 0 commands: 0.22 seconds. Total time spent compiling C/C++ extensions: 21.22 seconds. running install running install_lib byte-compiling /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages/sage/ext_data/nbconvert/postprocess.py to postprocess.cpython-37.pyc running install_egg_info Removing /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages/sage-9.1-py3.7.egg-info Writing /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages/sage-9.1-py3.7.egg-info Cleaning up stale installed files.... - cleaning /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages Cleaning up stale file: /mnt/d/Programming/Projects/sage/local/lib/python3.7/site-packages/sage/ext_data/nbconvert/__pycache__/postprocess.cpython-37.pyc - cleaning build/lib.linux-x86_64-3.7 Finished cleaning, time: 15.04 seconds. if [ "$UNAME" = "CYGWIN" ]; then \ sage-rebase.sh "$SAGE_LOCAL" 2>/dev/null; \ fi real 4m25.825s user 0m24.257s sys 0m36.241s tobias@DESKTOP-OMSMBL2:/mnt/d/Programming/Projects/sage$ On Sunday, May 31, 2020 at 3:07:40 PM UTC+2, Dima Pasechnik wrote: > > On Sun, May 31, 2020 at 1:59 PM Eric Gourgoulhon <egourg...@gmail.com > <javascript:>> wrote: > > > > Hi Tobias, > > > > Le dimanche 31 mai 2020 14:49:46 UTC+2, Tobias Diez a écrit : > >> > >> > >> For now I came up with the following workaround, which works but feels > like a huge hack: Create a file `/src/sage/test.py` with the following > content. You can then run this file using the local python (e.g. > ./local/bin/python3). Once you change the content of the package under > consideration (here manifolds), rerun the "Reload manifold packages..." > block, which reloads the files so that the changes take effect. This takes > about one second in contrast to the 5 min of `sage -b`. > > > > > > I'm surprised about this: usually, when I modify some source file in > src/sage/manifolds and I run sage -b afterwards, it takes only about 1 > second to rebuild Sage. > > > indeed, if you only touch a *.py file, it will be copied and > byte-compiled by ./sage -b, but this would be the only work done by > ./sage -b > > if you see more, it could either be that your setup touches a lot of > files, or you did actually touch *.pyx files yourself - and they take > more time to rebuild. > > > > Eric. > > > > -- > > You received this message because you are subscribed to the Google > Groups "sage-devel" group. > > To unsubscribe from this group and stop receiving emails from it, send > an email to sage-...@googlegroups.com <javascript:>. > > To view this discussion on the web visit > https://groups.google.com/d/msgid/sage-devel/b7b265b0-a3c4-48f4-9343-778c3504d424%40googlegroups.com. > > > -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/sage-devel/373944ae-da7f-48fd-a0fa-ff5c15e7988f%40googlegroups.com.