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

data: common: MapDataset: Fix random.sample() usage for Python 3.11 #5301

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

Conversation

Jmennius
Copy link

@Jmennius Jmennius commented Jun 3, 2024

Sampling from a set has been deprecated since Python 3.9 and was removed in 3.11.
Fix buy converting the set to a list before passing it to sample() (this is essentially what sample() was doing internally before).

Sampling from a set has been deprecated since Python 3.9
and was removed in 3.11.
Fix buy converting the set to a list before passing it to `sample()`
(this is essentially what `sample()` was doing internally before).

Signed-off-by: Ievgen Popovych <[email protected]>
@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Jun 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants