Skip to content

Fixed #1649 randrange bug - #1669

Merged
OpenSourceSimon merged 1 commit into
elebumm:developfrom
propilideno:develop
May 26, 2023
Merged

OpenSourceSimon merged 1 commit into
elebumm:developfrom
propilideno:develop

Conversation

@propilideno

Copy link
Copy Markdown
Contributor

Description

Fixing randrange bug, it usually happens when you try some rand values that are out of the range.

How i fix it

I keep dividing the initialValue by 2 until it reaches 0. If even with this divisions we can't determine a range, an exception should be raised.

Issue Fixes

Checklist:

  • I am pushing changes to the develop branch
  • I am using the recommended development environment
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have formatted and linted my code using python-black and pylint
  • I have cleaned up unnecessary files
  • My changes generate no new warnings
  • My changes follow the existing code-style
  • My changes are relevant to the project

Testing

image

@ghost

ghost commented May 26, 2023

Copy link
Copy Markdown
👇 Click on the image for a new way to code review

Review these changes using an interactive CodeSee Map

Legend

CodeSee Map legend

@propilideno propilideno mentioned this pull request May 26, 2023
2 tasks done
@propilideno propilideno changed the title Fix #1649 randrange bug Fixed #1649 randrange bug May 26, 2023

@OpenSourceSimon OpenSourceSimon left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks!

@OpenSourceSimon
OpenSourceSimon merged commit 91c607a into elebumm:develop May 26, 2023
richardokonicha pushed a commit to fugoku/RedditVideoMakerBot that referenced this pull request Oct 23, 2026
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.

2 participants