Skip to content

dune triggers opam 2 to report spurious switch warnings #1337

@jberdine

Description

@jberdine

If I have a dune-workspace file that contains contexts for opam switches, then when dune internally invokes opam config env --switch <switch> --sexp for any non-current switch, opam warns:

[NOTE] To make opam select the switch <switch> in the current shell, add --set-switch or set OPAMSWITCH

This message is likely helpful when run interactively, but it ought to be suppressed or redirected to a file in this case.

(Opening an issue here instead of for opam as it seems like dune can just redirect opam's stderr, but maybe not, and an opam change might be needed.)

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