← Back to issue list

feat: Comment out replace statements to relative paths in go.mod

View original Github issue

Metadata

Project
craft-parts
Number
#1466
Type
pull request
State
open
Author
atandrewlee
Labels
—
Created
Updated
Closed
—

Current evaluation

Adds awk-based stripping of relative replace directives in go.mod to the go-use plugin, plus an integration test. Its go.mod existence check was already merged separately; maintainer says *-use plugins are obsolete post-Madrid.

Suggested action: close stale

Reason: One of the two proposed changes already landed independently as PR #1478 (commit e5af6aab 'feat(go-use): error early if go.mod is missing'), and @steinbro stated on 2026-08-10 that 'the *-use plugins are effectively obsolete post-Madrid so the PR in its current form isn't relevant anymore', deferring to @tigarmo; the author has not responded for 53 days and had earlier called the awk approach unclean. Review status remains changes_requested with 2 unresolved comments, so the remaining replace-stripping shell logic has no maintainer acceptance.

Evaluated by: mr-cal-bot

Impact: 22 Quick Win: 2 Complexity: 45 Confidence: 78 Actionability: 15

Issue body

- [x] Have you followed the guidelines for contributing? - [x] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)? - [ ] Have you successfully run `make lint && make test`? - [ ] Have you added an entry to the changelog (`docs/reference/changelog.rst`)? --- From the discussion on the PR #1391, this PR adds logic to the `go-use` plugin 1. Checks if a `go.mod` exists or return an error 2. If the go.mod exists, it will remove replace statements that point to relative paths (starts with `./` or `../`) 3. An integration test to ensure this works (with both imports of one-line replace statements & multi line replace() blocks Note: I need to run make lint & test (I wasn't on an Ubuntu machine when developing this). Will do soon

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha
Impact: 22
Quick Win: 2
Complexity: 45
Confidence: 78
Actionability: 15
close stale Adds awk-based stripping of relative replace directives in go.mod to the go-use plugin, plus an integration test. Its go.mod existence check was already merged separately; maintainer says *-use plugins are obsolete post-Madrid.
qwen/qwen3.6-35b-a3b
Impact: 15
Quick Win: 1
Complexity: 30
Confidence: 85
Actionability: 10
close not mergeable PR modifies go-use plugin to comment out relative replace statements in go.mod. Maintainer @steinbro stated the *-use plugins are obsolete post-Madrid and the PR is no longer relevant. Author has not responded to this feedback in 42 days.
qwen/qwen3.8-27b
Impact: 35
Quick Win: 19
Staleness: 55
Complexity: 45
Confidence: 70
keep open Adds go-use plugin logic to strip relative-path replace statements from go.mod, with integration tests. Changes requested; maintainer notes *-use plugins are obsolete post-Madrid, deferring to tigarmo on whether to adapt to the newer Go plugin.
qwen/qwen3.6-35b-a3b
Staleness: 85
Complexity: 35
Confidence: 95
close stale Modifies go-use plugin to strip relative replace statements from go.mod. Review requested, CI has architecture-specific failures, maintainer notes the plugin is obsolete.
qwen/qwen3.6-35b-a3b
Staleness: 65
Complexity: 45
Confidence: 60
needs review Modifies go-use plugin to strip relative path replace statements from go.mod. Currently awaiting maintainer review with 7 unresolved comments and pending CI fixes.
qwen3.6-35b-a3b-mtp-q6
Staleness: 85
Complexity: 50
Confidence: 80
close stale Adds logic to go-use plugin to comment out relative path replace statements in go.mod. Currently inactive for over 3 months, awaiting maintainer feedback on implementation approach and missing CI checks.

Update history

Date Change
updated

Related work

  • Related To: craft-parts#1478 (confidence 88%)

    Merged PR that implements item 1 of this PR's description (go-use errors if go.mod missing), already present in craft_parts/plugins/go_use_plugin.py.

  • Related To: craft-parts#1391 (confidence 85%)

    Original issue/PR for relative-path replace directives; explicitly superseded by this PR's commenting-out approach.

Related issues

Issue Project State Summary Similarity
#1478 feat: go-use checks if go.mod exists; throws error if not craft-parts merged Merged as commit e5af6aab: go-use plugin now raises PartsError when no go.mod exists in the part source/subdir before running go work use; test added and changelog noted.
73%
#1391 Fix the use of go-use (Go Workspaces) when using dependencies that include `replace <dep> => <relative path` in the go.mod file craft-parts open go-use symlink-resolution fix for relative `replace` directives in dependency go.mod files; changes requested, 3 unresolved comments, test-other-plugins and title-policy CI failing, author moved the approach to PR #1466.
73%