Commit Graph
19196 Commits
Author SHA1 Message Date
Jörg Thalheimandmergify[bot] e3d71921c3 buffered-io: also check for interrupts in readline
This allows us to more reliable interrupt nix-eval-jobs
2023-12-17 12:15:15 +00:00
Jörg ThalheimandGitHub 4a1123c42d Merge pull request #289 from nix-community/joerg-ci
fix exit status reporting when evaluation fails
2023-12-16 17:15:45 +01:00
Jörg Thalheim b73f7ceff4 classify SIGSEV/SIGBUS as infinite recursion errors 2023-12-16 11:58:01 +01:00
Jörg Thalheim 093b8ce5cc apply treefmt 2023-12-16 11:44:08 +01:00
Jörg Thalheim b4f7eb3c77 fix ci for infinite recursion case 2023-12-16 11:40:34 +01:00
Jörg Thalheim 4d97e5a386 improve infinite recursion errors 2023-12-16 10:52:23 +01:00
Jörg Thalheim 83df9d4e24 fix exit status reporting when evaluation fails 2023-12-16 09:48:37 +01:00
Jörg Thalheim 89927c434c make sure we also define HAVE_STRUCT_DIRENT_D_TYPE outside of autotools 2023-12-16 09:24:42 +01:00
Jörg Thalheim 8daea338f3 flake.lock: Update
Flake lock file updates:

• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/0838486e9183ce39398f01b221766e68b50f405c' (2023-12-10)
  → 'github:NixOS/nixpkgs/203ecda835bcf69633df7183459283543dd4a874' (2023-12-15)
• Updated input 'treefmt-nix':
    'github:numtide/treefmt-nix/afdd5e48a0869b389027307652a658051c0d2f96' (2023-12-10)
  → 'github:numtide/treefmt-nix/d06b70e5163a903f19009c3f97770014787a080f' (2023-12-13)
2023-12-16 09:20:53 +01:00
Jörg Thalheim 4b6d34214d add include-what-you-use to devshell 2023-12-16 09:20:53 +01:00
Jörg Thalheim 1f4bbded61 optimize imports with "include-what-you-use" 2023-12-16 09:20:53 +01:00
renovate[bot]andmergify[bot] 843dc25cfe chore(deps): lock file maintenance 2023-12-11 00:21:12 +00:00
Jörg Thalheimandmergify[bot] 521380076d release proc.pid properly before calling waitpid() 2023-12-10 20:36:24 +00:00
Jörg Thalheimandmergify[bot] e1ad62cef1 include orignal json in worker error message 2023-12-10 20:36:24 +00:00
Jörg Thalheimandmergify[bot] d48cfadb3d fix catching eval errors on macOS 2023-12-10 20:36:24 +00:00
Jörg Thalheimandmergify[bot] c00fcbba8d drop obsolete compiler warning suppression 2023-12-10 20:36:24 +00:00
Jörg Thalheimandmergify[bot] b6ec7d2ecf make MyArgs non-copyable
this seems to have weird effects
2023-12-10 20:36:24 +00:00
Jörg Thalheimandmergify[bot] b24c03e2de simplify collector function
looks like the lambda doesn't buy us anything here.
2023-12-10 20:36:24 +00:00
Jörg ThalheimandGitHub 97dd8023e8 Merge pull request #283 from nix-community/joerg-ci
apply treefmt
2023-12-10 17:03:00 +01:00
Jörg Thalheim b267eb917d apply treefmt 2023-12-10 17:00:31 +01:00
Jörg Thalheim f970ec3524 add test for evaluation errors 2023-12-10 16:59:14 +01:00
Jörg Thalheimandmergify[bot] e7c30b306d don't fail nix-eval-jobs on eval errors
This error handling was copied by accident in https://github.com/nix-community/nix-eval-jobs/pull/277/commits/5c764d4a67feceae1848414fd9434e79120884e6#diff-a79ded172fd76747492a417a39848b6c25c14238e65971e6a05fe81706d5048fR622
2023-12-10 15:57:18 +00:00
Jörg Thalheimandmergify[bot] 36a5368dfc include missing filesystem header 2023-12-10 14:52:52 +00:00
Jörg Thalheimandmergify[bot] 3be8c48f54 fix format 2023-12-10 14:52:52 +00:00
Jörg Thalheimandmergify[bot] a03f039a56 split nix-eval-jobs further into smaller files 2023-12-10 14:52:52 +00:00
Jörg Thalheim 880c66a7d1 move drvs ot its own class 2023-12-10 15:07:38 +01:00
Jörg Thalheim db3099bc8f move argument parsing to new file 2023-12-10 14:22:32 +01:00
Jörg Thalheimandmergify[bot] 6f4bee53f6 nix-github-action: fix value beeing interpreted as bool 2023-12-10 10:25:15 +00:00
Jörg Thalheimandmergify[bot] f49cb87963 enable asan/ubsan in ci 2023-12-10 10:25:15 +00:00
Jörg Thalheimandmergify[bot] 00d3f014e7 print error if worker receives invalid command 2023-12-10 10:25:15 +00:00
Jörg Thalheimandmergify[bot] 93972c0c18 handle broken evaluation worker pipes on write 2023-12-10 10:25:15 +00:00
Jörg Thalheimandmergify[bot] 36483b325c treefmt: replace prettier with deno
we don't have toml files and deno has a smaller install closure.
2023-12-10 10:25:15 +00:00
Jörg Thalheimandmergify[bot] 5ad4e7266f handle broken evaluation worker pipes more gracefully
writeLine will throw a SysError exception, which obfuscates out-of-memory events where the eval worker is killed by the OS.
readLine is suffering from the same problem and will be handled in a subsequent commit.
2023-12-10 10:25:15 +00:00
Jörg Thalheimandmergify[bot] 40ad828088 update flakes to fix tests on macos 2023-12-10 08:31:27 +00:00
Jörg Thalheimandmergify[bot] fad244725f print which derivation failed to evaluate 2023-12-10 08:31:27 +00:00
Jörg ThalheimandGitHub 0f8e80f292 Merge pull request #276 from nix-community/joerg-ci
bump to 2.19.0
2023-12-06 09:56:32 +01:00
Jörg Thalheim 6f9a8d2cda bump to 2.19.0 2023-12-06 09:41:01 +01:00
Jörg Thalheimandmergify[bot] d4eeecf6b2 fix commandline parsing for nix 2.19 2023-12-06 08:30:10 +00:00
Jörg Thalheimandmergify[bot] c240e61481 fix missing includes for nix 2.19 2023-12-06 08:30:10 +00:00
Jörg Thalheimandmergify[bot] 34110992a8 flake.lock: Update
Flake lock file updates:

• Updated input 'flake-parts':
    'github:hercules-ci/flake-parts/8c9fa2545007b49a5db5f650ae91f227672c3877' (2023-11-01)
  → 'github:hercules-ci/flake-parts/34fed993f1674c8d06d58b37ce1e0fe5eebcb9f5' (2023-12-01)
• Updated input 'nix-github-actions':
    'github:nix-community/nix-github-actions/4bb5e752616262457bc7ca5882192a564c0472d2' (2023-11-03)
  → 'github:nix-community/nix-github-actions/93e39cc1a087d65bcf7a132e75a650c44dd2b734' (2023-11-28)
• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/5171694860f185961daff3b1b413dabcab421300' (2023-11-27)
  → 'github:NixOS/nixpkgs/9ed8ade77aef706a03d8cc3a5ad4f60848ac59a7' (2023-12-06)
• Updated input 'treefmt-nix':
    'github:numtide/treefmt-nix/e82f32aa7f06bbbd56d7b12186d555223dc399d1' (2023-11-12)
  → 'github:numtide/treefmt-nix/affe7fc3f5790e1d0b5ba51bcff0f7ebe465e92d' (2023-12-04)
2023-12-06 08:30:10 +00:00
John EricsonandGitHub 4a1c3762df Merge pull request #9543 from NixOS/backport-9542-to-2.18-maintenance
[Backport 2.18-maintenance] Add missing `-pthread` for test support libraries
2023-12-05 19:26:18 -05:00
John Ericsonandgithub-actions[bot] 615bd655e5 Add missing -pthread for test support libraries
This is good in general (see how the other libraries also have long had
it, since 49fe9592a4) but in particular
needed to fix the NetBSD build.

(cherry picked from commit b23273f6a29c725646b3523b1c35a0ae4a84ef61)
2023-12-05 23:44:41 +00:00
John EricsonandGitHub 211b6e1855 Merge pull request #9517 from NixOS/2.18-flatten-tests
[Backport 2.18-maintanence] Backport test source layout reorgs
2023-12-01 13:53:13 -05:00
John Ericson f7f37035c8 Move tests to separate directories, and document
Today, with the tests inside a `tests` intermingled with the
corresponding library's source code, we have a few problems:

- We have to be careful that wildcards don't end up with tests being
  built as part of Nix proper, or test headers being installed as part
  of Nix proper.

- Tests in libraries but not executables is not right:

  - It means each executable runs the previous unit tests again, because
    it needs the libraries.

  - It doesn't work right on Windows, which doesn't want you to load a
    DLL just for the side global variable . It could be made to work
    with the dlopen equivalent, but that's gross!

This reorg solves these problems.

There is a remaining problem which is that sibbling headers (like
`hash.hh` the test header vs `hash.hh` the main `libnixutil` header) end
up shadowing each other. This PR doesn't solve that. That is left as
future work for a future PR.

Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>

(cherry picked from commit 91b6833686a6a6d9eac7f3f66393ec89ef1d3b57)
(cherry picked from commit a61e42adb528b3d40ce43e07c79368d779a8b624)
2023-12-01 13:05:03 -05:00
John Ericson 30dcc19d1f Put functional tests in tests/functional
I think it is bad for these reasons when `tests/` contains a mix of
functional and integration tests

 - Concepts is harder to understand, the documentation makes a good
   unit vs functional vs integration distinction, but when the
   integration tests are just two subdirs within `tests/` this is not
   clear.

 - Source filtering in the `flake.nix` is more complex. We need to
   filter out some of the dirs from `tests/`, rather than simply pick
   the dirs we want and take all of them. This is a good sign the
   structure of what we are trying to do is not matching the structure
   of the files.

With this change we have a clean:
```shell-session
$ git show 'HEAD:tests'
tree HEAD:tests

functional/
installer/
nixos/
```

(cherry picked from commit 68c81c737571794f7246db53fb4774e94fcf4b7e)
2023-12-01 12:06:43 -05:00
John EricsonandGitHub 7242521265 Merge pull request #9514 from NixOS/2.18-nixpkgs-bump
[Backport 2.18-maintainence] nixpkgs bump
2023-12-01 11:30:05 -05:00
Robert HensingandJohn Ericson 016f936df6 flake.lock: Update
Flake lock file updates:

• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/31ed632c692e6a36cfc18083b88ece892f863ed4' (2023-09-21)
  → 'github:NixOS/nixpkgs/9ba29e2346bc542e9909d1021e8fd7d4b3f64db0' (2023-11-23)

(cherry picked from commit fe4f573d49a5c47cf9ffd0bd3fe8868104550818)
(cherry picked from commit f01baf5f0657ce58c9c14d7ab5de910f58e423c
2023-12-01 11:08:15 -05:00
renovate[bot]andmergify[bot] 608089054e chore(deps): update cachix/install-nix-action action to v24 2023-11-28 18:11:31 +00:00
Robert HensingandGitHub 083b198bb7 Merge pull request #9471 from NixOS/backport-9459-to-2.18-maintenance
[Backport 2.18-maintenance] add path based redirects
2023-11-27 15:15:52 +01:00
Valentin Gagarinandgithub-actions[bot] 8fb477a6e7 add path based redirects
up to now, those were managed outside of this repo, which as
unsurprisingly a real hassle to deal with if one wanted to prevent URLs
from breaking when moving pages around. this change removes a large part
of the friction involved in moving content in the Nix manual.

possible next steps for further automation:
- check for content that moved and warn if it's not reachable from
  links that were valid prior to a change
- create redirect rules automatically based on this information

(cherry picked from commit 2b7016cc56d12e67de9f1f25b18311866a26a5fe)
2023-11-27 13:29:00 +00:00