Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions other/password.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@
# Password Generator = full boot with random_number, random_letters, and
# random_character FUNCTIONS
# Put your code here...
if i < len(chars_incl):
raise ValueError(

Check failure on line 33 in other/password.py

View workflow job for this annotation

GitHub Actions / ruff

ruff (invalid-syntax)

other/password.py:33:5: invalid-syntax: Expected an indented block after `if` statement

Check failure on line 33 in other/password.py

View workflow job for this annotation

GitHub Actions / ruff

ruff (invalid-syntax)

other/password.py:33:5: invalid-syntax: Expected an indented block after `if` statement

Check failure on line 33 in other/password.py

View workflow job for this annotation

GitHub Actions / ruff

ruff (invalid-syntax)

other/password.py:33:5: invalid-syntax: Expected an indented block after `if` statement
"Password length must be at least the number of required characters"
)
Comment on lines +32 to +35

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Suggested change
if i < len(chars_incl):
raise ValueError(
"Password length must be at least the number of required characters"
)
if i < len(chars_incl):
raise ValueError(
"Password length must be at least the number of required characters"
)

The raise ValueError block must be indented under the if statement to avoid an IndentationError.

i -= len(chars_incl)
quotient = i // 3
remainder = i % 3
Expand Down
Loading