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: Fix 'possibly-used-before-assignment' pylint issues #440

Merged
Merged
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
5 changes: 5 additions & 0 deletions library/blivet.py
Original file line number Diff line number Diff line change
Expand Up @@ -642,6 +642,9 @@
self._device = None
return # TODO: see if we can create this device w/ the specified name

# pylint doesn't understand that "luks_fmt" is always set when "encrypted" is true
# pylint: disable=unknown-option-value
# pylint: disable=possibly-used-before-assignment
def _update_from_device(self, param_name):
""" Return True if param_name's value was retrieved from a looked-up device. """
log.debug("Updating volume settings from device: %r", self._device)
Expand Down Expand Up @@ -1717,6 +1720,8 @@

if auto_size_dev_count > 0:
calculated_thinlv_size = available_space / auto_size_dev_count
else:
calculated_thinlv_size = available_space

Check warning on line 1724 in library/blivet.py

View check run for this annotation

Codecov / codecov/patch

library/blivet.py#L1724

Added line #L1724 was not covered by tests

for thinlv in thinlvs_to_create:

Expand Down
Loading