Skip to content

Commit

Permalink
pkg: repro for crash when with-dev-setup is used (#10539)
Browse files Browse the repository at this point in the history
Adds a test case demonstrating a crash when a package refers to the
`with-dev-setup` opam variable.

Signed-off-by: Stephen Sherratt <stephen@sherra.tt>
  • Loading branch information
gridbugs committed May 17, 2024
1 parent 745254e commit 944b294
Showing 1 changed file with 22 additions and 4 deletions.
26 changes: 22 additions & 4 deletions test/blackbox-tests/test-cases/pkg/common-filters-deps.t
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,28 @@ included.
> EOF
$ mkpkg doc <<EOF
> EOF
$ mkpkg dev-setup <<EOF
> EOF
Note that dune solves packages with with-doc always set to false, so
documentation-only deps are omitted from the solution.
$ solve "(test :with-test) (doc :with-doc) (dev :with-dev) (build :build) (post :post)"
Solution for dune.lock:
- build.0.0.1
- test.0.0.1
$ solve "(test :with-test) (doc :with-doc) (dev-setup :with-dev-setup) (dev :with-dev) (build :build) (post :post)"
Internal error, please report upstream including the contents of _build/log.
Description:
("Unexpected exception raised while solving dependencies",
{ exception = "Invalid_argument(\"filter_deps\")" })
Raised at Stdune__Code_error.raise in file
"otherlibs/stdune/src/code_error.ml", line 10, characters 30-62
Called from Fiber__Scheduler.exec in file "vendor/fiber/src/scheduler.ml",
line 76, characters 8-11
Re-raised at Stdune__Exn.raise_with_backtrace in file
"otherlibs/stdune/src/exn.ml", line 38, characters 27-56
Called from Fiber__Scheduler.exec in file "vendor/fiber/src/scheduler.ml",
line 76, characters 8-11
I must not crash. Uncertainty is the mind-killer. Exceptions are the
little-death that brings total obliteration. I will fully express my cases.
Execution will pass over me and through me. And when it has gone past, I
will unwind the stack along its path. Where the cases are handled there will
be nothing. Only I will remain.
[1]

0 comments on commit 944b294

Please sign in to comment.