anchor.diff:    postPatch = ''
       # Remove selenium tests
       rm -rf notebook/tests/selenium
  -
  +    export HOME=$TMPDIR
     '';
   
  -  checkPhase = ''
  -    runHook preCheck
  -    mkdir tmp
  -    HOME=tmp nosetests -v ${if (stdenv.isDarwin) then ''
  -      --exclude test_delete \
  -      --exclude test_checkpoints_follow_file
  -    ''
  -    else ""}
  -  '';
  +  disabledTests = [
  +    # a "system_config" is generated, and fails many tests
  +    "config"
  +    "load_ordered"
  +    # requires jupyter, but will cause circular imports
  +    "test_run"
  +    "TestInstallServerExtension"
  +    "launch_socket"
  +    "sock_server"
  +  ];
   
     # Some of the tests use localhost networking.
     __darwinAllowLocalNetworking = true;
  
positive.code: , lib
  , buildPythonPackage
  , fetchPypi
  , nose
  , nose_warnings_filters
  , glibcLocales
  
negative.code: 
    LC_ALL = "en_US.utf8";
  
    checkInputs = [ nose pytestCheckHook glibcLocales ]
      ++ (if isPy3k then [ nose_warnings_filters ] else [ mock ]);
  
    propagatedBuildInputs = [
      jinja2 tornado ipython_genutils traitlets jupyter_core send2trash
      jupyter_client nbformat nbconvert ipykernel terminado requests pexpect
      prometheus_client argon2_cffi
    ];
  
    # disable warning_filters
  