Skip to content

Commit

Permalink
internal/mod/modload: remove debugging panic with sprintf
Browse files Browse the repository at this point in the history
I introduced this code two days ago in https://cuelang.org/cl/1195701
and while developing, I had used Sprintf to inspect error values
and panic to loudly surface when they happened in our test suite.

Unfortunately, I forgot the panic and it made it past code review too.

Signed-off-by: Daniel Martí <mvdan@mvdan.cc>
Change-Id: I881d2e6ca2979470d7253b2bab0625644829975e
Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1195847
TryBot-Result: CUEcueckoo <cueckoo@cuelang.org>
Reviewed-by: Rustam Abdullaev <rustam@cue.works>
  • Loading branch information
mvdan committed Jun 6, 2024
1 parent a229224 commit 889da91
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions internal/mod/modload/tidy.go
Original file line number Diff line number Diff line change
Expand Up @@ -181,8 +181,6 @@ func (ld *loader) resolveDependencies(ctx context.Context, rootPkgPaths []string
if errors.As(err, &missingErr) {
err = &ErrModuleNotTidy{Reason: fmt.Sprintf(
"missing dependency providing package %s", missingErr.Path)}
} else {
panic(fmt.Sprintf("%#v\n", err) + ": " + err.Error())
}
return nil, nil, err
}
Expand Down

0 comments on commit 889da91

Please sign in to comment.