Skip to content
Snippets Groups Projects
  1. Oct 23, 2013
  2. Oct 22, 2013
  3. Oct 18, 2013
  4. Oct 17, 2013
    • Eelco Dolstra's avatar
      Fold two stack trace messages in derivations · 792fd51f
      Eelco Dolstra authored
      Combined with the previous changes, stack traces involving derivations
      are now much less verbose, since something like
      
        while evaluating the builtin function `getAttr':
        while evaluating the builtin function `derivationStrict':
        while instantiating the derivation named `gtk+-2.24.20' at `/home/eelco/Dev/nixpkgs/pkgs/development/libraries/gtk+/2.x.nix:11:3':
        while evaluating the derivation attribute `propagatedNativeBuildInputs' at `/home/eelco/Dev/nixpkgs/pkgs/stdenv/generic/default.nix:78:17':
        while evaluating the attribute `outPath' at `/nix/store/212ngf4ph63mp6p1np2bapkfikpakfv7-nix-1.6/share/nix/corepkgs/derivation.nix:18:9':
        ...
      
      now reads
      
        while evaluating the attribute `propagatedNativeBuildInputs' of the derivation `gtk+-2.24.20' at `/home/eelco/Dev/nixpkgs/pkgs/development/libraries/gtk+/2.x.nix:11:3':
        ...
      792fd51f
    • Eelco Dolstra's avatar
      Don't show <nix/derivation.nix> in stack traces · f440558a
      Eelco Dolstra authored
      Messages like
      
        while evaluating the attribute `outPath' at `/nix/store/212ngf4ph63mp6p1np2bapkfikpakfv7-nix-1.6/share/nix/corepkgs/derivation.nix:18:9':
      
      are redundant, because Nix already shows that it's evaluating a derivation:
      
        while instantiating the derivation named `firefox-24.0' at `/home/eelco/Dev/nixpkgs/pkgs/applications/networking/browsers/firefox/default.nix:131:5':
        while evaluating the derivation attribute `nativeBuildInputs' at `/home/eelco/Dev/nixpkgs/pkgs/stdenv/generic/default.nix:76:17':
      f440558a
    • Eelco Dolstra's avatar
      Nix 1.6.1 release notes · bb659bad
      Eelco Dolstra authored
      bb659bad
    • Eelco Dolstra's avatar
      Fix test · f6a8e7f4
      Eelco Dolstra authored
      f6a8e7f4
  5. Oct 16, 2013
    • Eelco Dolstra's avatar
      Test string semantics a bit more · b08f4b0d
      Eelco Dolstra authored
      b08f4b0d
    • goblin's avatar
      two typos · d7625b5c
      goblin authored
      d7625b5c
    • Eelco Dolstra's avatar
      Ensure proper type checking/coercion of "${expr}" · b8034e55
      Eelco Dolstra authored
      Now we only rewrite "${expr}" to expr if expr is a string literal.
      b8034e55
    • Eelco Dolstra's avatar
      Add a test for type correctness of antiquotes · 9d8a8037
      Eelco Dolstra authored
      Antiquotes should evaluate to strings or paths.  This is usually
      checked, except in the case where the antiquote makes up the entire
      string, as in "${expr}".  This is optimised to expr, which discards
      the runtime type checks / coercions.
      9d8a8037
    • Eelco Dolstra's avatar
      Revert the behaviour of antiquoted paths to pre-Nix 1.6 · d6a7aa8f
      Eelco Dolstra authored
      Commit 159e621d accidentally changed
      the behaviour of antiquoted paths, e.g.
      
        "${/foo}/bar"
      
      used to evaluate to "/nix/store/<hash>-foo/bar" (where /foo gets
      copied to the store), but in Nix 1.6 it evaluates to "/foo/bar".  This
      is inconsistent, since
      
        " ${/foo}/bar"
      
      evaluates to " /nix/store/<hash>-foo/bar".  So revert to the old
      behaviour.
      d6a7aa8f
    • Eelco Dolstra's avatar
      Add a regression test for correct path antiquotation behavior · b8571d68
      Eelco Dolstra authored
      This broke in Nix 1.6.
      b8571d68
    • Eelco Dolstra's avatar
      Retry all SQLite operations · a737f51f
      Eelco Dolstra authored
      To deal with SQLITE_PROTOCOL, we also need to retry read-only
      operations.
      a737f51f
    • Eelco Dolstra's avatar
      Fix a race in registerFailedPath() · ff02f533
      Eelco Dolstra authored
      Registering the path as failed can fail if another process does the
      same thing after the call to hasPathFailed().  This is extremely
      unlikely though.
      ff02f533
    • Eelco Dolstra's avatar
      4bd52825
    • Eelco Dolstra's avatar
      Don't wrap read-only queries in a transaction · bce14d0f
      Eelco Dolstra authored
      There is no risk of getting an inconsistent result here: if the ID
      returned by queryValidPathId() is deleted from the database
      concurrently, subsequent queries involving that ID will simply fail
      (since IDs are never reused).
      bce14d0f
    • Eelco Dolstra's avatar
      7cdefdbe
    • Eelco Dolstra's avatar
      Treat SQLITE_PROTOCOL as SQLITE_BUSY · d05bf044
      Eelco Dolstra authored
      In the Hydra build farm we fairly regularly get SQLITE_PROTOCOL errors
      (e.g., "querying path in database: locking protocol").  The docs for
      this error code say that it "is returned if some other process is
      messing with file locks and has violated the file locking protocol
      that SQLite uses on its rollback journal files."  However, the SQLite
      source code reveals that this error can also occur under high load:
      
        if( cnt>5 ){
          int nDelay = 1;                      /* Pause time in microseconds */
          if( cnt>100 ){
            VVA_ONLY( pWal->lockError = 1; )
            return SQLITE_PROTOCOL;
          }
          if( cnt>=10 ) nDelay = (cnt-9)*238;  /* Max delay 21ms. Total delay 996ms */
          sqlite3OsSleep(pWal->pVfs, nDelay);
        }
      
      i.e. if certain locks cannot be not acquired, SQLite will retry a
      number of times before giving up and returing SQLITE_PROTOCOL.  The
      comments say:
      
        Circumstances that cause a RETRY should only last for the briefest
        instances of time.  No I/O or other system calls are done while the
        locks are held, so the locks should not be held for very long. But
        if we are unlucky, another process that is holding a lock might get
        paged out or take a page-fault that is time-consuming to resolve,
        during the few nanoseconds that it is holding the lock.  In that case,
        it might take longer than normal for the lock to free.
        ...
        The total delay time before giving up is less than 1 second.
      
      On a heavily loaded machine like lucifer (the main Hydra server),
      which often has dozens of processes waiting for I/O, it seems to me
      that a page fault could easily take more than a second to resolve.
      So, let's treat SQLITE_PROTOCOL as SQLITE_BUSY and retry the
      transaction.
      
      Issue NixOS/hydra#14.
      d05bf044
  6. Oct 14, 2013
    • Eelco Dolstra's avatar
      nix-shell: Fix bash completion · c1994fec
      Eelco Dolstra authored
      Nixpkgs's stdenv setup script sets the "nullglob" option, but doing so
      breaks Bash completion on NixOS (when ‘programs.bash.enableCompletion’
      is set) and on Ubuntu.  So clear that flag afterwards.  Of course,
      this may break stdenv functions in subtle ways...
      c1994fec
  7. Oct 11, 2013
  8. Oct 08, 2013
  9. Oct 07, 2013
    • Eelco Dolstra's avatar
      Don't show calls to primops in stack traces · 176c666f
      Eelco Dolstra authored
      Since they don't have location information, they just give you crap
      like:
      
        while evaluating the builtin function `getAttr':
        while evaluating the builtin function `derivationStrict':
        ...
      176c666f
  10. Oct 02, 2013
  11. Sep 18, 2013
  12. Sep 17, 2013
  13. Sep 10, 2013
  14. Sep 06, 2013
Loading