Skip to content

test(pkg): dependency cycles are tolerated or crash - #15619

Merged
Alizter merged 1 commit into
ocaml:mainfrom
Alizter:push-slxvukqtykum
Jul 31, 2026
Merged

Alizter merged 1 commit into
ocaml:mainfrom
Alizter:push-slxvukqtykum

Conversation

@Alizter

@Alizter Alizter commented Jul 29, 2026

Copy link
Copy Markdown
Collaborator

Description

Add regression coverage for dependency cycles reachable from local packages:

  • A hand-written cycle between lock-directory packages is silently accepted by validation.
  • A cycle between workspace packages is accepted by validation, then crashes dune describe pkg list-locked-dependencies --transitive with an internal error.

This captures the current behavior before the combined dependency-graph traversal and user-facing cycle diagnostics are introduced.

Related Issue and Motivation

Part of #8652.

Checklist

  • Tests added, if applicable.
  • Change log entry not applicable; this is a test-only change.
  • Documentation not applicable; this is a test-only change.

Dependency cycles reachable from the local packages are user-writable
input: hand-written lock directories can close a cycle through their
dependency lists, and workspace packages can depend on each other.
Validation silently accepts both, deferring lockdir cycles to a build
failure, and querying the transitive dependencies of a workspace cycle
crashes with a Code_error.

Signed-off-by: Ali Caglayan <[email protected]>
@Alizter
Alizter force-pushed the push-slxvukqtykum branch from 700e40d to b139438 Compare July 31, 2026 13:47
@Alizter
Alizter merged commit cf7f759 into ocaml:main Jul 31, 2026
35 of 36 checks passed
@Alizter
Alizter deleted the push-slxvukqtykum branch July 31, 2026 14:00
@Alizter Alizter added this to the 3.25.0 milestone Aug 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant