Skip to content

Select importers when go.mod / go.sum dependencies change #84

Open

Description

@adityankale190895

Part of #76.

Any change to go.mod or go.sum falls back today (Language/framework configuration changed: go.mod). So does every Dependabot or Renovate bump. The JS side already narrows a lockfile change to the dependencies that changed (see yarn.lock/package-lock.json handling and #66), and Go can do the same.

Proposal

  • Diff the base and head go.mod (require versions only) and go.sum. When only the versions of some modules changed, select the local packages whose go list -deps closure includes a package from those modules.
  • The go list output already lists each dependency package's Module.Path, so the adapter needs to record, for each local package, which external modules it reaches.

Must fall back (blocker)

  • Any change to the go / toolchain line, replace, exclude, retract or godebug.
  • A changed module that go list can't resolve offline.
  • go.sum changes not explained by the go.mod diff.

Done when

  • A fixture where a imports github.com/x/y and b doesn't shows that bumping y selects only a, and adding a replace still falls back.

Activity

  1. added
    enhancement
    help wanted
    on Nov 9, 2026
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

    adapterenhancementhelp wanted

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions