Skip to content

Do not use an upper bound on dependencies, unless you have to #253

@abelbraaksma

Description

@abelbraaksma

Description

Whenever xUnit is updated beyond what this package assumes, NU1608 warnings are raised. This issue was introduced in the latest v5.5.0, it was not present in v5.4.0.

(side note, I don't see any PR for the last 8 days, and the new version is 8 days old, so I can't really find what caused this...)

Repro steps

Just include this library through Nuget and upgrade the xUnit dependency to the latest version 2.6.1

Expected behavior

No warnings.

Actual behavior

Warning:

Warning NU1608: Detected package version outside of dependency constraint: FsUnit.xUnit 5.5.0 requires xunit (>= 2.5.3 && < 2.6.0) but version xunit 2.6.1 was resolved.

Known workarounds

Either ignore the warning, or downgrade to FsUnit.xUnit 5.4.0, which does not have this issue.

Related information

Version FsUnit.xUnit 5.5.0

Maybe there's a good reason for not supporting the 2.6+ range, but so far, it works "just fine" if I ignore the warning. In general, dependencies should have a lowest bound, ideally as low as possible for backward compatibility, but no upper bound, for the simple reason that we cannot predict what future versions will bring.

Note that this is how the FSharp.Core dependency was set, no upperbound:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions