Skip to content

Upgrading Go version from 1.24 to 1.26#4737

Open
karwaankit32 wants to merge 9 commits intoprebid:masterfrom
karwaankit32:go-version-upgrade
Open

Upgrading Go version from 1.24 to 1.26#4737
karwaankit32 wants to merge 9 commits intoprebid:masterfrom
karwaankit32:go-version-upgrade

Conversation

@karwaankit32
Copy link
Copy Markdown
Contributor

@karwaankit32 karwaankit32 commented Apr 1, 2026

Upgrading Go version build from 1.24 and 1.26.
Doing version compatibility fixes

  • Fixed Go 1.26 compatibility in timeout handling by recognizing wrapped context deadline exceeded errors
  • Cleaned up formatting-related code by removing unnecessary fmt.Sprintf usage where a static string was sufficient. If not done, it fails during go vet and tests also fail

Testing
Ran all Unit tests
Tested following endpoints -

  • /cookie_sync
  • /openrtb/auction

@karwaankit32 karwaankit32 marked this pull request as draft April 1, 2026 05:52
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 1, 2026

Code coverage summary

Note:

  • Prebid team doesn't anticipate tests covering code paths that might result in marshal and unmarshal errors
  • Coverage summary encompasses all commits leading up to the latest one, 0e39f66

adapterstest

Refer here for heat map coverage report

github.com/prebid/prebid-server/v4/adapters/adapterstest/adapter_test_util.go:23:	BidOnTags			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/adapter_test_util.go:33:	SampleBid			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/adapter_test_util.go:46:	VerifyStringValue		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/adapter_test_util.go:53:	VerifyIntValue			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/adapter_test_util.go:60:	VerifyBoolValue			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/adapter_test_util.go:67:	VerifyBannerSize		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:70:		RunJSONBidderTest		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:83:		RunSingleJSONBidderTest		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:105:		loadFile			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:127:		runSpec				0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:135:		getTestExtraRequestInfo		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:185:		expectsErrors			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:194:		ToRequestData			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:215:		ToResponseData			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:244:		assertMakeRequestsOutput	0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:279:		assertErrorList			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:307:		assertMakeBidsOutput		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:336:		diffHttpRequests		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:371:		diffBids			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:386:		diffOrtbBids			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:399:		diffBidVideo			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:410:		diffJson			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:448:		testMakeRequestsImpl		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:469:		getDataRaceTestCopies		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:490:		testMakeBidsImpl		0.0%
total:											(statements)			0.0%

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 1, 2026

Code coverage summary

Note:

  • Prebid team doesn't anticipate tests covering code paths that might result in marshal and unmarshal errors
  • Coverage summary encompasses all commits leading up to the latest one, 068c6d3

adapterstest

Refer here for heat map coverage report

github.com/prebid/prebid-server/v4/adapters/adapterstest/adapter_test_util.go:23:	BidOnTags			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/adapter_test_util.go:33:	SampleBid			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/adapter_test_util.go:46:	VerifyStringValue		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/adapter_test_util.go:53:	VerifyIntValue			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/adapter_test_util.go:60:	VerifyBoolValue			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/adapter_test_util.go:67:	VerifyBannerSize		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:70:		RunJSONBidderTest		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:83:		RunSingleJSONBidderTest		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:105:		loadFile			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:127:		runSpec				0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:135:		getTestExtraRequestInfo		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:185:		expectsErrors			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:194:		ToRequestData			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:215:		ToResponseData			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:244:		assertMakeRequestsOutput	0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:279:		assertErrorList			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:307:		assertMakeBidsOutput		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:336:		diffHttpRequests		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:371:		diffBids			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:386:		diffOrtbBids			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:399:		diffBidVideo			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:410:		diffJson			0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:448:		testMakeRequestsImpl		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:469:		getDataRaceTestCopies		0.0%
github.com/prebid/prebid-server/v4/adapters/adapterstest/test_json.go:490:		testMakeBidsImpl		0.0%
total:											(statements)			0.0%

@karwaankit32 karwaankit32 marked this pull request as ready for review April 1, 2026 06:31
@karwaankit32 karwaankit32 requested a review from SyntaxNode April 1, 2026 06:31
@SyntaxNode
Copy link
Copy Markdown
Contributor

Curious, entire json and yaml files are showing up as a change. Did you inadvertently change the line endings?

Comment thread .github/workflows/adapter-code-coverage.yml Outdated
Comment thread .github/workflows/validate-merge.yml Outdated
Comment thread .github/workflows/validate.yml Outdated
Comment thread adapters/adapterstest/adapter_test_util.go
Comment thread endpoints/openrtb2/amp_auction_test.go
Comment thread exchange/bidder_test.go Outdated
mockMetricEngine := &metrics.MetricsEngineMock{}
expectedAdapterName := openrtb_ext.BidderAppnexus
compareConnWaitTime := func(dur time.Duration) bool { return dur.Nanoseconds() > 0 }
compareConnWaitTime := func(dur time.Duration) bool { return dur >= 0 }
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Why is this change needed?

Comment thread modules/fiftyonedegrees/devicedetection/hook_raw_auction_request.go
Comment thread Dockerfile Outdated
Comment thread go.mod Outdated
module github.com/prebid/prebid-server/v4

go 1.23.0
go 1.24
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

We support the latest two releases, so the minimum version here should be 1.25.

Comment thread README.md Outdated
## Developing

Prebid Server requires [Go](https://go.dev) version 1.23 or newer. You can develop on any operating system that Go supports; however, please note that our helper scripts are written in bash.
Prebid Server requires [Go](https://go.dev) version 1.24 or newer. You can develop on any operating system that Go supports; however, please note that our helper scripts are written in bash.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Same here 1.25.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Using 1.25 starts making the webhooks fail. Also, current version being used is 1.24, shouldn't we be setting it to that?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Using 1.25 starts making the webhooks fail.

What do you mean?

current version being used is 1.24

This PR is upgrading the current version to 1.26. Since we support current and current-1, we use current-1 version here for the tool chain to ensure compatability.

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

Successfully merging this pull request may close these issues.

3 participants