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

fix: replace deprecated rand.Seed #1436

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

tenthirtyam
Copy link
Collaborator

Summary

rand.Seed has been deprecated since Go 1.20 and an alternative has been available since Go 1.0.

As of Go 1.20 there is no reason to call Seed with a random value. Programs that call Seed with a known value to get a specific sequence of results should use New(NewSource(seed)) to obtain a local random generator.

`rand.Seed` has been deprecated since Go 1.20 and an alternative has been available since Go 1.0.

As of Go 1.20 there is no reason to call `Seed` with a random value. Programs that call `Seed` with a known value to get a specific sequence of results should use `New(NewSource(seed))` to obtain a local random generator.
@tenthirtyam tenthirtyam added technical-debt Technical Debt chore Chore labels Oct 16, 2024
@tenthirtyam tenthirtyam self-assigned this Oct 16, 2024
@tenthirtyam tenthirtyam added needs-review Needs Review size/xs Relative Sizing: extra-small labels Oct 16, 2024
Copy link
Member

@salv-orlando salv-orlando left a comment

Choose a reason for hiding this comment

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

LGTM. @ksamoray can you please have a look at this?

@ksamoray
Copy link
Collaborator

LGTM. @ksamoray can you please have a look at this?

Already did - but would rather wait to have a CI for acceptance tests before merging this (and few of the other changes).

@tenthirtyam
Copy link
Collaborator Author

@vmware/terraform-provider-nsxt-maintainers: reminder.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chore Chore needs-review Needs Review size/xs Relative Sizing: extra-small technical-debt Technical Debt
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants