Skip to content

Error when running go install github.com/DarthSim/overmind/v2@latest w/in a repo that uses it. #177

Closed

Description

@jasondborneman

Our repo has a /setup script that installs requirements, one of which is overmind (go install github.com/DarthSim/overmind/v2@latest). It runs this within our repo. This worked fine until the replace directive was added into overmind's go.mod: https://github.com/DarthSim/overmind/blob/master/go.mod#L20

Now when trying to run our setup it bombs out when reaching the overmind install step with the following error:

go: github.com/DarthSim/overmind/v2@latest (in github.com/DarthSim/overmind/[email protected]):
        The go.mod file for the module providing named packages contains one or
        more replace directives. It must not contain directives that would cause
        it to be interpreted differently than if it were the main module.

In fact, I tried running go install github.com/DarthSim/overmind/v2@latest even outside our repo and still get that same error.

We are on go version 1.22.1, btw

Activity

  1. changed the title [-]Error when running `go install github.com/vektra/mockery/v2@latest` w/in a repo that uses it.[/-] [+]Error when running `go install github.com/DarthSim/overmind/v2@latest` w/in a repo that uses it.[/+] on Mar 25, 2024
  2. Envek commented on Mar 26, 2024

    @Envek
    Collaborator

    This golang limitation is freaking me out: golang/go#44840

    But anyway, removed replace directive and tagged 2.5.1 so it should work now, thanks for reporting.

  3. jasondborneman commented on Mar 26, 2024

    @jasondborneman
    Author

    This golang limitation is freaking me out: golang/go#44840

    But anyway, removed replace directive and tagged 2.5.1 so it should work now, thanks for reporting.

    Can confirm this fixed our issue. Thanks! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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