From 8d238b3f0448985fe1a127f47296f3320285989a Mon Sep 17 00:00:00 2001 From: dbenoit Date: Mon, 1 Dec 2025 10:51:56 -0500 Subject: [PATCH] Update to Delve 1.25.2 (Sync from CentOS Stream 9) Related: RHEL-121223 --- .fmf/version | 1 + .gitignore | 9 ++- delve.spec | 21 ++++--- modify-tests.patch => modify-ports.patch | 28 ++++----- plans/gating.fmf | 8 +++ skip-coredump-test.patch | 78 ------------------------ skip-substitute-path-test.patch | 42 ------------- sources | 2 +- 8 files changed, 42 insertions(+), 147 deletions(-) create mode 100644 .fmf/version rename modify-tests.patch => modify-ports.patch (69%) create mode 100644 plans/gating.fmf delete mode 100644 skip-coredump-test.patch delete mode 100644 skip-substitute-path-test.patch diff --git a/.fmf/version b/.fmf/version new file mode 100644 index 0000000..d00491f --- /dev/null +++ b/.fmf/version @@ -0,0 +1 @@ +1 diff --git a/.gitignore b/.gitignore index 7d876e8..49c2c70 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,13 @@ -SOURCES/delve-1.9.1.tar.gz +/delve-1.4.0.tar.gz +/delve-1.4.1.tar.gz +/delve-1.5.0.tar.gz +/delve-1.6.0.tar.gz +/delve-1.7.2.tar.gz +/delve-1.7.3.tar.gz +/delve-1.8.3.tar.gz /delve-1.9.1.tar.gz /delve-1.20.2.tar.gz /delve-1.21.2.tar.gz /delve-1.22.1.tar.gz /delve-1.24.1.tar.gz +/delve-1.25.2.tar.gz diff --git a/delve.spec b/delve.spec index 11ce26c..bf70f08 100644 --- a/delve.spec +++ b/delve.spec @@ -3,7 +3,7 @@ %endif Name: delve -Version: 1.24.1 +Version: 1.25.2 Release: 1%{?dist} Summary: A debugger for the Go programming language @@ -18,15 +18,14 @@ BuildRequires: git BuildRequires: lsof Provides: dlv = %{version} -Patch1: skip-coredump-test.patch -Patch2: skip-substitute-path-test.patch +Patch0001: modify-ports.patch %description -Delve is a debugger for the Go programming language. The goal of the project -is to provide a simple, full featured debugging tool for Go. Delve should be -easy to invoke and easy to use. Chances are if you're using a debugger, things -aren't going your way. With that in mind, Delve should stay out of your way as +Delve is a debugger for the Go programming language. The goal of the project +is to provide a simple, full featured debugging tool for Go. Delve should be +easy to invoke and easy to use. Chances are if you're using a debugger, things +aren't going your way. With that in mind, Delve should stay out of your way as much as possible. @@ -58,8 +57,8 @@ install -Dpm 0755 bin/dlv %{buildroot}%{_bindir}/dlv export GO111MODULE=off export GOPATH="%{_builddir}/%{name}-%{version}/_build" cd "_build/src/github.com/go-delve/%{name}" -for d in $(go list %{?exp} ./... | grep -v cmd | grep -v scripts); do - go test %{?exp} ${d} +for d in $(go list %{?exp} ./... | grep -v cmd | grep -v scripts | grep -v service/dap); do + go test %{?exp} ${d} -skip TestGuessSubstitutePath done @@ -71,6 +70,10 @@ done %changelog +* Thu Aug 28 2025 David Benoit - 1.25.2-1 +- Update to Delve 1.25.2 (Sync from CentOS Stream 9) +- Related: RHEL-121223 + * Fri Mar 14 2025 David Benoit - 1.24.1-1 - Rebase to 1.24.1 - Skip unsupported tests diff --git a/modify-tests.patch b/modify-ports.patch similarity index 69% rename from modify-tests.patch rename to modify-ports.patch index 6e4d8ee..0939534 100644 --- a/modify-tests.patch +++ b/modify-ports.patch @@ -1,4 +1,4 @@ -From 0d8ba2001ceacd67a8861f470399f695cabc8802 Mon Sep 17 00:00:00 2001 +From 1ba9183936e11839811cf27472677d44ea4eb1a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lex=20S=C3=A1ez?= Date: Wed, 24 Jan 2024 13:10:29 +0100 Subject: [PATCH] Modify tests @@ -7,9 +7,9 @@ Some tests are not working properly with the build system so we need to adapt them, like changing the ports they used. --- _fixtures/notify-v2.go | 2 +- - pkg/proc/proc_test.go | 3 +++ + pkg/proc/proc_test.go | 6 ++++++ pkg/terminal/command_test.go | 2 +- - 3 files changed, 5 insertions(+), 2 deletions(-) + 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/_fixtures/notify-v2.go b/_fixtures/notify-v2.go index eb80526b..0f562c27 100644 @@ -23,30 +23,26 @@ index eb80526b..0f562c27 100644 + log.Fatalln(http.ListenAndServe("127.0.0.1:8889", nil)) } diff --git a/pkg/proc/proc_test.go b/pkg/proc/proc_test.go -index 714a4d1d..ea1d94a9 100644 +index 714a4d1d..ae9f0bd9 100644 --- a/pkg/proc/proc_test.go +++ b/pkg/proc/proc_test.go -@@ -2512,6 +2512,7 @@ func TestStepConcurrentDirect(t *testing.T) { +@@ -2512,6 +2512,9 @@ func TestStepConcurrentDirect(t *testing.T) { } func TestStepConcurrentPtr(t *testing.T) { -+ t.Skipf("Skipping due to CI issues") ++ if runtime.GOARCH == "ppc64le" { ++ t.Skipf("Skipping due to CI issues") ++ } protest.AllowRecording(t) withTestProcess("teststepconcurrent", t, func(p *proc.Target, grp *proc.TargetGroup, fixture protest.Fixture) { setFileBreakpoint(p, t, fixture.Source, 24) -@@ -5491,6 +5492,7 @@ func TestWatchpointCounts(t *testing.T) { - skipOn(t, "not implemented", "386") - skipOn(t, "see https://github.com/go-delve/delve/issues/2768", "windows") - skipOn(t, "not implemented", "ppc64le") -+ skipOn(t, "fails on CI", "arm64") - protest.AllowRecording(t) - - withTestProcess("databpcountstest", t, func(p *proc.Target, grp *proc.TargetGroup, fixture protest.Fixture) { -@@ -6080,6 +6082,7 @@ func TestEscapeCheckUnreadable(t *testing.T) { +@@ -6080,6 +6083,9 @@ func TestEscapeCheckUnreadable(t *testing.T) { } func TestStepShadowConcurrentBreakpoint(t *testing.T) { -+ t.Skipf("Skipping due to CI issues") ++ if runtime.GOARCH == "ppc64le" { ++ t.Skipf("Skipping due to CI issues") ++ } // Checks that a StepBreakpoint can not shadow a concurrently hit user breakpoint withTestProcess("stepshadow", t, func(p *proc.Target, grp *proc.TargetGroup, fixture protest.Fixture) { break2 := setFunctionBreakpoint(p, t, "main.stacktraceme2") diff --git a/plans/gating.fmf b/plans/gating.fmf new file mode 100644 index 0000000..7698be8 --- /dev/null +++ b/plans/gating.fmf @@ -0,0 +1,8 @@ +summary: Gating tests +discover: + - name: rhel + how: fmf + url: https://gitlab.cee.redhat.com/toolchain-qe/tests/delve.git + filter: tier:1 +execute: + how: tmt diff --git a/skip-coredump-test.patch b/skip-coredump-test.patch deleted file mode 100644 index 03f5d36..0000000 --- a/skip-coredump-test.patch +++ /dev/null @@ -1,78 +0,0 @@ -From d5fb3bee427202f0d4b1683bf743bfd2adb41757 Mon Sep 17 00:00:00 2001 -From: Derek Parker -Date: Thu, 20 Mar 2025 01:15:19 -0700 -Subject: [PATCH] proc/core: skip tests on ppc64le (#3954) - -These tests have been somewhat silently failing on our CI because the -test ends up being skipped [due to the lack of coredumpctl](https://delve.teamcity.com/buildConfiguration/Delve_linux_ppc64le_1_24/66766?buildTab=tests&focusLine=NaN&name=testcore&suite=github.com%2Fgo-delve%2Fdelve%2Fpkg%2Fproc%2Fcore%3A+&expandedTest=build%3A%28id%3A66766%29%2Cid%3A2000000704&showLog=66766_20670_112.20612.20670&logFilter=debug&logView=flowAware). - -When `coredumpctl` is present, the test [fails -anyways](https://issues.redhat.com/browse/RHEL-83939), so let's just -skip it on ppc64le for now. ---- - pkg/proc/core/core_test.go | 41 +++++++++++++++++++++----------------- - 1 file changed, 23 insertions(+), 18 deletions(-) - -diff --git a/pkg/proc/core/core_test.go b/pkg/proc/core/core_test.go -index dddc1d3e7..52b210b6f 100644 ---- a/pkg/proc/core/core_test.go -+++ b/pkg/proc/core/core_test.go -@@ -249,15 +249,8 @@ func logRegisters(t *testing.T, regs proc.Registers, arch *proc.Arch) { - } - - func TestCore(t *testing.T) { -- if runtime.GOOS != "linux" || runtime.GOARCH == "386" { -- t.Skip("unsupported") -- } -- if runtime.GOOS != "linux" || runtime.GOARCH == "loong64" { -- t.Skip("could not read runtime.sigtrampgo context") -- } -- if runtime.GOOS == "linux" && os.Getenv("CI") == "true" && buildMode == "pie" { -- t.Skip("disabled on linux, Github Actions, with PIE buildmode") -- } -+ mustSupportCore(t) -+ - grp := withCoreFile(t, "panic", "") - p := grp.Selected - -@@ -412,15 +405,8 @@ func TestCoreFpRegisters(t *testing.T) { - } - - func TestCoreWithEmptyString(t *testing.T) { -- if runtime.GOOS != "linux" || runtime.GOARCH == "386" { -- t.Skip("unsupported") -- } -- if runtime.GOOS != "linux" || runtime.GOARCH == "loong64" { -- t.Skip("could not read runtime.sigtrampgo context") -- } -- if runtime.GOOS == "linux" && os.Getenv("CI") == "true" && buildMode == "pie" { -- t.Skip("disabled on linux, Github Actions, with PIE buildmode") -- } -+ mustSupportCore(t) -+ - grp := withCoreFile(t, "coreemptystring", "") - p := grp.Selected - -@@ -536,3 +522,22 @@ func procdump(t *testing.T, exePath string) string { - t.Fatalf("could not find dump file") - return "" - } -+ -+func mustSupportCore(t *testing.T) { -+ t.Helper() -+ -+ if runtime.GOOS != "linux" { -+ t.Skip("test must be run on linux") -+ } -+ -+ switch runtime.GOARCH { -+ case "386", "ppc64le": -+ t.Skip("unsupported") -+ case "loong64": -+ t.Skip("could not read runtime.sigtrampgo context") -+ } -+ -+ if os.Getenv("CI") == "true" && buildMode == "pie" { -+ t.Skip("disabled on linux, Github Actions, with PIE buildmode") -+ } -+} diff --git a/skip-substitute-path-test.patch b/skip-substitute-path-test.patch deleted file mode 100644 index f234e60..0000000 --- a/skip-substitute-path-test.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 55486fbab43420d67323cd3e79cda115e7e687c6 Mon Sep 17 00:00:00 2001 -From: Derek Parker -Date: Thu, 20 Mar 2025 01:14:20 -0700 -Subject: [PATCH] service/test: skip substitutepath test when modules disabled - (#3955) - -See: https://issues.redhat.com/browse/RHEL-83958 ---- - pkg/proc/test/support.go | 6 ++++++ - service/test/integration2_test.go | 2 ++ - 2 files changed, 8 insertions(+) - -diff --git a/pkg/proc/test/support.go b/pkg/proc/test/support.go -index d1f25bd49..c8efea360 100644 ---- a/pkg/proc/test/support.go -+++ b/pkg/proc/test/support.go -@@ -392,6 +392,12 @@ func MustHaveCgo(t *testing.T) { - } - } - -+func MustHaveModules(t *testing.T) { -+ if os.Getenv("GO111MODULE") == "off" { -+ t.Skip("skipping test which requires go modules") -+ } -+} -+ - func RegabiSupported() bool { - // Tracks regabiSupported variable in ParseGOEXPERIMENT internal/buildcfg/exp.go - switch { -diff --git a/service/test/integration2_test.go b/service/test/integration2_test.go -index 9ef131a3e..2e3928fb8 100644 ---- a/service/test/integration2_test.go -+++ b/service/test/integration2_test.go -@@ -3157,6 +3157,8 @@ func TestBreakpointVariablesWithoutG(t *testing.T) { - } - - func TestGuessSubstitutePath(t *testing.T) { -+ protest.MustHaveModules(t) -+ - t.Setenv("NOCERT", "1") - ver, _ := goversion.Parse(runtime.Version()) - if ver.IsDevelBuild() && os.Getenv("CI") != "" && runtime.GOOS == "linux" { diff --git a/sources b/sources index b71893d..b6f646a 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (delve-1.24.1.tar.gz) = 7308339af2ef0da14b3d1860d99a602f6fdf3861afd12fd25930c2587bec3099905d3c74ae3d93a193d9aebc77bea4eb4fe3878e3a84c45616ea9926d6b6ba27 +SHA512 (delve-1.25.2.tar.gz) = 4696ad39625d1aa9866154ecb4ebb6bbfc58faa56db598324e224ca5f877193c4bb5124f3741c68ae1fc82b2ebc24cb4310651cfc83a944fbb2ef5edc3d115e7