Eelco Dolstra
29dff7e24e
Merge remote-tracking branch 'origin/master' into lazy-trees
2023-01-11 13:26:20 +01:00
Eelco Dolstra
d33d15a48b
Put the --show-trace hint in the logical place
2023-01-02 20:53:58 +01:00
Eelco Dolstra
6b69652385
Merge remote-tracking branch 'origin/master' into coerce-string
2023-01-02 20:53:39 +01:00
Eelco Dolstra
64c60f7241
Fix CanonPath::dirOf() returning a string_view of a temporary
...
https://hydra.nixos.org/build/202837872
2022-12-23 15:32:54 +01:00
Eelco Dolstra
15d2e0e63b
Merge remote-tracking branch 'origin/master' into tmp
2022-12-20 13:50:16 +01:00
Eelco Dolstra
8332ac6a1d
Merge pull request #7451 from edolstra/abstract-pos
...
Introduce AbstractPos
2022-12-20 12:55:13 +01:00
Eelco Dolstra
d00bfe4833
Merge pull request #7450 from edolstra/canon-path
...
Add CanonPath wrapper to represent canonicalized paths
2022-12-19 16:21:11 +01:00
Eelco Dolstra
8becbb063a
Merge remote-tracking branch 'origin/master' into lazy-trees
2022-12-14 14:02:36 +01:00
Eelco Dolstra
b3fdab28a2
Introduce AbstractPos
...
This makes the position object used in exceptions abstract, with a
method getSource() to get the source code of the file in which the
error originated. This is needed for lazy trees because source files
don't necessarily exist in the filesystem, and we don't want to make
libutil depend on the InputAccessor type in libfetcher.
2022-12-13 00:50:43 +01:00
Eelco Dolstra
900b854084
Add CanonPath wrapper to represent canonicalized paths
2022-12-12 19:57:32 +01:00
Florian Friesdorf
8618c6cc75
Simplify loop, feedback from @tfc and @Ericson2314
2022-12-12 18:41:00 +00:00
Florian Friesdorf
d269976be6
Show stack trace above error message
...
Save developers from scrolling by displaying the error message last,
below the stack trace.
2022-12-12 18:41:00 +00:00
Florian Friesdorf
173dcb0af9
Don't reverse stack trace when showing
...
When debugging nix expressions the outermost trace tends to be more useful
than the innermost. It is therefore printed last to save developers from
scrolling.
2022-12-12 18:41:00 +00:00
Eelco Dolstra
12c554acd4
Merge remote-tracking branch 'origin/master' into lazy-trees
2022-12-12 17:53:06 +01:00
Eelco Dolstra
786402365e
Cleanup
2022-12-12 12:40:51 +01:00
Eelco Dolstra
8272cd9dec
Optimize string concatenation
...
Co-authored-by: Théophane Hufschmitt <7226587+thufschmitt@users.noreply.github.com>
2022-12-12 12:36:19 +01:00
Eelco Dolstra
703d863a48
Trivial changes from the lazy-trees branch
2022-12-07 14:06:34 +01:00
Eelco Dolstra
730f6bf616
Merge remote-tracking branch 'origin/master' into lazy-trees
2022-12-07 11:35:59 +01:00
Eelco Dolstra
fcdca3d776
Merge remote-tracking branch 'origin/master' into lazy-trees
2022-12-05 13:05:18 +01:00
Jörg Thalheim
cccd57c022
getMaxCPU: fix cgroup path
...
Given this typo I am not sure if it has been tested.
2022-12-04 18:22:12 +01:00
Eelco Dolstra
fa99ef6a87
getMaxCPU(): Lower verbosity level for ignored exceptions
...
Fixes #7268 .
2022-12-02 15:03:40 +01:00
Eelco Dolstra
1e6a5d1ff6
Clean up cgroup handling in getMaxCPU()
...
Also, don't assume in LocalDerivationGoal that cgroups are mounted on
/sys/fs/cgroup.
2022-12-02 12:59:13 +01:00
Eelco Dolstra
1211e59a03
Move cgroup.{cc,hh} to libutil
2022-12-02 12:38:03 +01:00
Eelco Dolstra
fbc53e97ed
Merge pull request #3600 from NixOS/auto-uid-allocation
...
Automatic UID allocation
2022-11-29 14:01:42 +01:00
Eelco Dolstra
653b32a78f
Merge remote-tracking branch 'origin/master' into auto-uid-allocation
2022-11-21 11:33:23 +01:00
Eelco Dolstra
128910ba23
Separate cgroup support from auto-uid-allocation
...
The new experimental feature 'cgroups' enables the use of cgroups for
all builds. This allows better containment and enables setting
resource limits and getting some build stats.
2022-11-18 10:39:28 +01:00
Eelco Dolstra
f1ab082ac4
createTempDir(): Use std::atomic
2022-11-18 09:37:11 +01:00
Yorick van Pelt
09f00dd4d0
Replace src/libutil/json.cc with nlohmann json generation
2022-11-16 16:50:50 +01:00
Eelco Dolstra
561440bd6d
Merge remote-tracking branch 'origin/master' into lazy-trees
2022-11-16 15:07:22 +01:00
Eelco Dolstra
6c6eff8ac4
Remove the SystemdCgroup feature
2022-11-10 17:24:12 +01:00
Eelco Dolstra
40911d7dec
Remove stray tab
2022-11-04 13:30:35 +01:00
Eelco Dolstra
b95faccf03
Merge remote-tracking branch 'origin/master' into auto-uid-allocation
2022-11-03 17:43:40 +01:00
Yorick van Pelt
34ea0e2e7b
tarfile: set directory mode to at least 0500, don't extract fflags
...
We don't need SGID, or any ACL's. We also want to keep every dir +rx.
2022-11-01 16:01:38 +01:00
Eelco Dolstra
a653e98f55
Encode virtual paths as /nix/store/virtual000<N>
...
This makes lib.isStorePath in nixpkgs return true for source trees and
fixes some cases where /__nix_virtual__ showed up in the NixOS manual.
2022-10-27 15:57:56 +02:00
Guillaume Maudoux
e93bf69b44
Rework error throwing, and test it
2022-10-25 01:46:10 +02:00
Guillaume Maudoux
b945b844a9
Initial frames support
2022-10-17 03:05:02 +02:00
Guillaume Maudoux
3f9f6ae127
Merge remote-tracking branch 'origin/master' into coerce-string
2022-10-16 20:39:19 +02:00
Eelco Dolstra
511590976c
Fix handling of relative paths
...
In particular, 'path:..' got turned into 'path:.' because isRelative()
returned a CanonPath, which cannot represent '..'.
Reported by @erikarvstedt.
2022-10-10 18:56:19 +02:00
Eelco Dolstra
5c8d67d553
Merge remote-tracking branch 'origin/master' into lazy-trees
2022-10-10 14:51:22 +02:00
Eelco Dolstra
241dd5481e
warnOnce(): Fix boost exception when the message contains a format character
2022-09-30 15:21:43 +02:00
Eelco Dolstra
c3c0682842
Don't show "from call site" when we don't know the call site
...
This gets rid of stack trace entries like
… from call site
at «stdin»:0: (source not available)
2022-09-28 17:01:16 +02:00
Eelco Dolstra
28b62dd3e0
Merge remote-tracking branch 'origin/master' into lazy-trees
2022-09-28 14:13:44 +02:00
squalus
223f8dace0
archive: check close errors when extracting nars
2022-09-22 12:50:32 -07:00
squalus
1b595026e1
Improve durability of schema version file writes
...
- call close explicitly in writeFile to prevent the close exception
from being ignored
- fsync after writing schema file to flush data to disk
- fsync schema file parent to flush metadata to disk
https://github.com/NixOS/nix/issues/7064
2022-09-19 20:13:30 -07:00
Eelco Dolstra
d365cced4f
Trim option descriptions
...
This removes unintended blank lines in Markdown when the description
is a multiline string literal.
2022-09-13 16:58:32 +02:00
Guillaume Maudoux
eb460a9529
WIP: broken merge but need a git checkpoint
2022-09-07 00:34:03 +02:00
Eelco Dolstra
034340aa9f
Fix potential duplicate activity IDs in forked child processes
2022-08-26 13:14:04 +02:00
Eelco Dolstra
def7b251d0
readLittleEndian(): Fix 64-bit integer truncation
...
Fixes #6939 .
2022-08-26 13:10:42 +02:00
Eelco Dolstra
13c0db4d06
Merge remote-tracking branch 'origin/master' into lazy-trees
2022-08-25 17:41:12 +02:00
Eelco Dolstra
bb411e4ae1
Fix progress bar flicker with -L
...
This was caused by -L calling setLogFormat() again, which caused the
creation of a new progress bar without destroying the old one. So we
had two progress bars clobbering each other.
We should change 'logger' to be a smart pointer, but I'll do that in a
future PR.
Fixes #6931 .
2022-08-24 22:36:40 +02:00