Skip to content
This repository has been archived by the owner on Feb 9, 2024. It is now read-only.

[7.0.x] Fix sortorder dep #2085

Merged
merged 3 commits into from
Sep 3, 2020
Merged

Conversation

bernardjkim
Copy link
Contributor

@bernardjkim bernardjkim commented Sep 1, 2020

Description

The vbom.ml domain was taken down and this broke the vbom.ml/util/sortorder dependency: fvbommel/util#6. This PR adds a temporary workaround by replacing the import paths from vbom.ml/util/sortorder -> github.com/fvbommel/sortorder.

Usage

  • make fix-sortorder should be run after updating dependencies. This will update the import paths.
  • make dep-ensure combines dep ensure and fix-sortorder target.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • Internal change (not necessarily a bug fix or a new feature)

Linked tickets and other PRs

Additional information

When attempting to update dependencies using dep, the update fails with the follow issue:

$ dep ensure
Solving failure: unable to deduce repository and source type for "vbom.ml/util": unable to read metadata: unable to fetch raw metadata: failed HTTP request to URL "http://vbom.ml/util?go-get=1": Get http://vbom.ml/util?go-get=1: dial tcp: lookup vbom.ml on 127.0.0.53:53: no such host

@bernardjkim bernardjkim requested review from a team, r0mant and knisbet September 1, 2020 18:33
@bernardjkim bernardjkim changed the title [7.0.x] Fix sorter dep [7.0.x] Fix sortorder dep Sep 1, 2020
Copy link
Contributor

@r0mant r0mant left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How should this target be used when updating dependencies?

@a-palchikov
Copy link
Contributor

How does it affect version/7.0.x? All I saw were issues with go mod which is not used in 7.x.
As a side note, would it be possible to workaround this with making vbom.ml/util/sortorder an explicit dependency (i.e. list in Gopkg.toml) and create an alias to the new location?

@bernardjkim
Copy link
Contributor Author

@a-palchikov
I've tried making vbom.ml/util/sortorder an explicit dependency and specifying a source, but it didn't seem to fix the issue. Not sure if I implemented it correctly or if there is a different way to create an alias, but this is what I tried.

[[override]]
  name = "vbom.ml/util/sortorder"
  source = "github.com/fvbommel/sortorder"
  version = "v1.0.1"
$ dep ensure
The following issues were found in Gopkg.toml:

  ✗ unable to deduce repository and source type for "vbom.ml/util/sortorder": unable to read metadata: unable to fetch raw metadata: failed HTTP request to URL "http://vbom.ml/util/sortorder?go-get=1": Get http://vbom.ml/util/sortorder?go-get=1: dial tcp: lookup vbom.ml on 127.0.0.53:53: no such host

ProjectRoot name validation failed

@a-palchikov
Copy link
Contributor

a-palchikov commented Sep 1, 2020

Ok, it looks like it's an old issue with dep.
Maybe we can wrap it as a make target - something like make dep-ensure - so it does the replacement automatically?

@bernardjkim
Copy link
Contributor Author

@r0mant, @a-palchikov
Added some additional information on issue with 7.0.x, and added a usage section in the original comment for information on make target usages. Use target make dep-ensure will update the dependencies and also fix sortorder import paths.

@bernardjkim bernardjkim merged commit 07335ab into version/7.0.x Sep 3, 2020
@bernardjkim bernardjkim deleted the bernard/7.0.x/fix-sortorder branch September 3, 2020 03:09
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants