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

replace math/rand with math/rand/v2 #861

Merged
merged 1 commit into from
Aug 25, 2024
Merged

Conversation

catatsuy
Copy link
Member

This pull request includes several changes to update the math/rand package to math/rand/v2 and to replace the deprecated rand.Intn function with the new rand.IntN function across multiple files.

Package Update and Function Replacement:

  • bench/asset/asset.go: Updated import from math/rand to math/rand/v2 and replaced rand.Intn with rand.IntN in multiple functions, including GetRandomActiveSellerIDs, GetRandomBuyerIDs, GetRandomImageFileName, GetRandomRootCategory, GetRandomChildCategory, GetRandomChildCategoryByParentID, and GenText. [1] [2] [3] [4] [5]
  • bench/scenario/campaign.go: Updated import from math/rand to math/rand/v2 and replaced rand.Intn with rand.IntN in the popularListing function. [1] [2]
  • bench/scenario/normal.go: Updated import from math/rand to math/rand/v2.
  • bench/server/shipment.go: Updated import from math/rand to math/rand/v2 and replaced rand.Intn with rand.IntN in the Set method of the shipmentStore struct. [1] [2]

@catatsuy catatsuy merged commit f0776fc into master Aug 25, 2024
4 checks passed
@catatsuy catatsuy deleted the feature-refactor-use-rand-v2 branch August 25, 2024 06:35
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.

1 participant