Fix non-reproducibilities caused by time-dependent procedures. Submitted upstream: https://github.com/ipython/ipython/pull/13640 diff --git a/IPython/sphinxext/ipython_directive.py b/IPython/sphinxext/ipython_directive.py index 18bdfcae9..2c665ac87 100644 --- a/IPython/sphinxext/ipython_directive.py +++ b/IPython/sphinxext/ipython_directive.py @@ -19,7 +19,7 @@ In [1]: 1+1 In [1]: import datetime - ...: datetime.datetime.now() + ...: datetime.date.fromisoformat('2022-02-22') It supports IPython construct that plain Python does not understand (like magics): @@ -28,7 +28,7 @@ In [0]: import time - In [0]: %timeit time.sleep(0.05) + In [0]: %pdoc time This will also support top-level async when using IPython 7.0+ -scripts Wojtek's customized Guix
aboutsummaryrefslogtreecommitdiff
path: root/nix
AgeCommit message (Expand)Author
2018-01-11daemon: Always try to execute the builder regardless of the platform....* nix/libstore/build.cc (runChild): Move platform check after 'execve' call. Check specifically for ENOEXEC. Ludovic Courtès
2018-01-07daemon: Make libbz2 an optional dependency....* config-daemon.ac: Don't bail out when libbz2 is missing. Define 'HAVE_LIBBZ2' Automake conditional. * nix/libstore/build.cc: Wrap relevant bits in '#if HAVE_BZLIB_H'. * nix/libstore/globals.cc (Settings::Settings): 'logCompression' defaults to COMPRESSION_GZIP when HAVE_BZLIB_H is false. * nix/libstore/globals.hh (CompressionType): Make 'COMPRESSION_BZIP2' conditional on HAVE_BZLIB_H. * nix/local.mk (guix_register_LDADD, guix_daemon_LDADD): Add -lbz2 only when HAVE_LIBBZ2. * nix/nix-daemon/guix-daemon.cc (parse_opt): Ignore "bzip2" when not HAVE_BZLIB_H. Ludovic Courtès
2018-01-07daemon: Add gzip log compression....* nix/nix-daemon/guix-daemon.cc (GUIX_OPT_LOG_COMPRESSION): New macro. (options): Mark "disable-log-compression" as hidden and add "log-compression". (parse_opt): Handle GUIX_OPT_LOG_COMPRESSION. * nix/libstore/build.cc (DerivationGoal): Add 'gzLogFile'. (openLogFile): Initialize it when 'logCompression' is COMPRESSION_GZIP. (closeLogFile, handleChildOutput): Honor 'gzLogFile'. * nix/libstore/globals.hh (Settings)[compressLog]: Remove. [logCompression]: New field. (CompressionType): New enum. * nix/libstore/globals.cc (Settings::Settings): Initialize it. (update): Remove '_get' call for 'compressLog'. * nix/local.mk (guix_daemon_LDADD, guix_register_LDADD): Add -lz. * guix/store.scm (log-file): Handle '.gz' log files. * tests/guix-daemon.sh: Add test with '--log-compression=gzip'. * doc/guix.texi (Invoking guix-daemon): Adjust accordingly. * config-daemon.ac: Check for libz and zlib.h. Ludovic Courtès
2017-12-31list-runtime-root: Fix off-by-one in 'strip-drop' call....Fixes <https://bugs.gnu.org/29862>. Reported by Danny Milosavljevic <dannym@scratchpost.org>. * nix/scripts/list-runtime-roots.in (canonicalize-store-item): Define 'store' with a trailing "/". Have the 'string-prefix?' call match the 'string-drop' call. Ludovic Courtès
2017-11-26list-runtime-roots: Ignore ESRCH while reading from /proc....Fixes <https://bugs.gnu.org/29368>. Reported by Martin Castillo <castilma@uni-bremen.de>. * nix/scripts/list-runtime-roots.in (referenced-files): Ignore ESRCH. Ludovic Courtès
2017-11-12list-runtime-roots: Ignore PIDs we cannot access....This allows running as non-root. Fixes a regression introduced in b8f59cdc20e9d83ce63523ef917e95fcee07f134. * nix/scripts/list-runtime-roots.in (referenced-files): Handle EACCES in addition to ENOENT. Ludovic Courtès
2017-11-12list-runtime-roots: Canonicalize store items....Looking at 'addAdditionalRoots' in libstore/gc.cc, it looks like it should always have been this way. In practice it probably doesn't make much of a difference. * nix/scripts/list-runtime-roots.in (canonicalize-store-item): New procedure. <top level>: Use it. Ludovic Courtès
2017-11-12list-runtime-roots: Do not use 'lsof'....This makes things a bit faster (0.8s instead of 1.4s on my laptop). * nix/scripts/list-runtime-roots.in (lsof-roots): Remove. (proc-fd-roots): Return the empty list when 'scandir' returns #f. (referenced-files): New procedure. Use it at the top level. Ludovic Courtès