-
Notifications
You must be signed in to change notification settings - Fork 412
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
dune crashes on dune pkg lock
#11058
Comments
It used to work before with the same configuration, I just upgraded the nightly dune. After some investigation, the regressions started appearing in version nightly-2024-10-22. Output of
|
Thanks for reporting! 👍 |
This looks like a regression caused by #11022. Can you post your depopts so we can build a reproduction case? As a short-term fix, you need to simplify the optional dependencies, to be only a list of packages that don't use |
I can take a look since I introduced the issue. |
Here's a link to a reproduction repository: https://github.com/maxrn/dune-pkg-repro |
Just simplified the example, cohttp-unix-lwt seems to be causing problems. EDIT: Minimal
|
Thanks. Do you mind repro'ing with dune in main? This PR should improve the error message. |
Internal error, please report upstream including the contents of _build/log.
Description:
("invalid depopts",
{ depopts =
Or
[ Or [ Atom ("tls-lwt", Empty); Atom ("lwt_ssl", Empty) ]
; Atom ("launchd", Empty)
]
})
Raised at Stdune__Code_error.raise in file
"otherlibs/stdune/src/code_error.ml", line 10, characters 30-62
Called from Dune_pkg__Opam_solver.resolve_depopts in file
"src/dune_pkg/opam_solver.ml", line 565, characters 3-21
Called from Dune_pkg__Opam_solver.opam_package_to_lock_file_pkg in file
"src/dune_pkg/opam_solver.ml", line 645, characters 6-48
Called from Stdlib__List.rev_map.rmap_f in file "list.ml", line 105,
characters 22-25
Called from Stdune__List.map in file "otherlibs/stdune/src/list.ml"
(inlined), line 5, characters 19-33
Called from Dune_pkg__Opam_solver.solve_lock_dir.(fun) in file
"src/dune_pkg/opam_solver.ml", line 856, characters 8-277
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" (inlined), line 38, characters 27-56
Called from Stdune__Exn_with_backtrace.reraise in file
"otherlibs/stdune/src/exn_with_backtrace.ml", line 20, characters 33-71
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. with latest dune nightly "Dune Developer Preview: build 2024-11-01T02:24:10Z, git revision
3ac95e5f1dfa4738faa197330a64555bbaec5421" Let me know if you need the |
Signed-off-by: Rudi Grinberg <me@rgrinberg.com> <!-- ps-id: 435862bf-91ef-4750-bf38-10336954f242 -->
Signed-off-by: Rudi Grinberg <me@rgrinberg.com> <!-- ps-id: 435862bf-91ef-4750-bf38-10336954f242 -->
Signed-off-by: Rudi Grinberg <me@rgrinberg.com> <!-- ps-id: 435862bf-91ef-4750-bf38-10336954f242 -->
Ran into this in my travels. It happens whenever a package has 3 or more depopts. Opam represents this as |
Repro: #11100 |
Expected Behavior
dune doesn't crash and the lock dir is generated.
Actual Behavior
dune crashes.
Reproduction
Output of
_build/log
https://gist.github.com/maxRN/27b87ae926eece0f98c54780547bd6eb
Specifications
Version of
dune
(output ofdune --version
):"Dune Developer Preview: build 2024-10-30T02:16:37Z, git revision d84d83a4becd373549757d907ba4e4d5434c5e0f"
Version of
ocaml
(output ofocamlc --version
): nonenothing
Operating system (distribution and version): MacOS Sonoma 15.1
Additional information
I'm using the dune developer preview.
dune
with the--verbose
flag): https://gist.github.com/maxRN/397e812820c48daf518a579c321d6ed1The text was updated successfully, but these errors were encountered: