Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't build v1.4.1 with Go 1.11 anymore due to use of strings.ReplaceAll() #2077

Closed
antiphp opened this issue Jun 8, 2020 · 3 comments
Closed

Comments

@antiphp
Copy link

antiphp commented Jun 8, 2020

Hey,

Issue #2018 / v1.4.1 introduced the use of strings.ReplaceAll so go install with Go 1.11 is not working anymore:
https://github.com/go-delve/delve/blame/708eadd5538edd222d8553b08b47c295474f38fa/pkg/proc/native/proc_linux.go#L170

# github.com/go-delve/delve/pkg/proc/native
../go/pkg/mod/github.com/go-delve/delve@v1.4.1/pkg/proc/native/proc_linux.go:170:16: undefined: strings.ReplaceAll

Since it's not really necessary to break it, especially in a bugfix version, I'd suggest to not use strings.ReplaceAll().

@antiphp antiphp changed the title Cant build v1.4.1 with Go 1.11 anymore due to use of strings.ReplaceAll() Can't build v1.4.1 with Go 1.11 anymore due to use of strings.ReplaceAll() Jun 8, 2020
@chainhelen
Copy link
Contributor

duplicate #2067

We only test and support the three most recent versions of Go. Use a more recent version of Go or a less recent version of Delve.

@antiphp
Copy link
Author

antiphp commented Jun 9, 2020

I generally agree with this policy - there must be a cut somewhere. But I would have hoped for a better reason than just a convenience string function that could have been avoided pretty easily and (more important) introducing that in a patch version. How could someone know that this version is breaking and this one is not. Maybe one could pin a delve version to a set of Go versions... Anyways thanks for pointing it out.

@aarzilli
Copy link
Member

@antiphp it is indeed unfortunate that this happened. If there was a way to test that we are not using API that are too new (without running tests on a much larger test matrix) I'd be for it.

How could someone know that this version is breaking and this one is not.

As it stands release 1.x.0 of delve will be tested against go 1.1x, 1.1(x-1) and 1.1(x-2), so 1.4.0 is guaranteed to build on 1.14, 1.13 and 1.12, but it could also accidentally build and work with older versions of Go.

Noeda added a commit to AdRoll/batchiepatchie that referenced this issue Aug 12, 2020
Batchiepatchie indirectly depends on go-delve, and that project no
longer works on go 1.11: go-delve/delve#2077

This commit just bumps the Golang version in the Dockerfile to 1.15 to
make it work.
Noeda added a commit to AdRoll/batchiepatchie that referenced this issue Aug 12, 2020
* Fix problems with old dependencies, by updating them.

Batchiepatchie frontend would no longer run out of box with `npm run
dev` like in `frontend/README.md` instructions.

Batchiepatchie's node dependencies have not been updated in a while and
things started breaking. This commit updates just enough dependencies to
make it still run properly.

* Update frontend/README.md and yarn lock file.

* Upgrade golang version to 1.15.

Batchiepatchie indirectly depends on go-delve, and that project no
longer works on go 1.11: go-delve/delve#2077

This commit just bumps the Golang version in the Dockerfile to 1.15 to
make it work.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants