Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/3.9-devel' into 3.9-release
Browse files Browse the repository at this point in the history
  • Loading branch information
vojtechtrefny committed Feb 27, 2024
2 parents fbbcfe9 + 94adfec commit c8fa34f
Show file tree
Hide file tree
Showing 8 changed files with 25 additions and 13 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ work to other active development branches and to ``master``.
``git push``

- if there is no ``x.{y+1}-devel``, merge it onto ``{x+1}.y`` branches
as appopriate, oldest-to-newest
as appropriate, oldest-to-newest

For example, if you already merged onto ``2.1-devel`` and there is
no ``2.2-devel``, the next place to merge would be ``3.0-devel`` if
Expand Down
2 changes: 1 addition & 1 deletion blivet/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
import warnings
import syslog

from . import util, arch
from . import arch

import logging
log = logging.getLogger("blivet")
Expand Down
4 changes: 2 additions & 2 deletions blivet/fstab.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def __init__(self):
self.freq = None
self.passno = None

# prefered spec identification type; default "UUID"
# preferred spec identification type; default "UUID"
# possible values: None, "UUID", "LABEL", "PARTLABEL", "PARTUUID", "PATH"
self.spec_type = None

Expand Down Expand Up @@ -296,7 +296,7 @@ def __init__(self, src_file=None, dest_file=None):
self.src_file = src_file
self.dest_file = dest_file

# prefered spec identification type; default "UUID"
# preferred spec identification type; default "UUID"
# possible values: None, "UUID", "LABEL", "PARTLABEL", "PARTUUID", "PATH"
self.spec_type = None

Expand Down
13 changes: 11 additions & 2 deletions blivet/populator/helpers/mdraid.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
from ...devicelibs import raid
from ...devices import MDRaidArrayDevice, MDContainerDevice
from ...devices import device_path_to_name
from ...errors import DeviceError, NoParentsError
from ...errors import DeviceError, NoParentsError, MDRaidError
from ...flags import flags
from ...storage_log import log_method_call
from .devicepopulator import DevicePopulator
Expand All @@ -58,7 +58,10 @@ def run(self):
return None

# try to get the device again now that we've got all the parents
device = self._devicetree.get_device_by_device_id("MDRAID-" + name, incomplete=flags.allow_imperfect_devices)
if name:
device = self._devicetree.get_device_by_device_id("MDRAID-" + name, incomplete=flags.allow_imperfect_devices)
else:
device = None

if device is None:
try:
Expand Down Expand Up @@ -219,6 +222,12 @@ def run(self):

self._devicetree.handle_device(array_info, update_orig_fmt=True)

if flags.auto_dev_updates and md_array and not md_array.status and md_array.complete:
try:
md_array.setup()
except MDRaidError:
log.warning("failed to activate MD array %s", md_array.name)

def update(self):
# update array based on current md data
pass
4 changes: 2 additions & 2 deletions doc/intro.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Introduction to Blivet
Blivet is a python module for system storage configuration.

The main thing that blivet offers is the ability to model a series of changes
without necessarily commiting any of the changes to disk. You can schedule an
without necessarily committing any of the changes to disk. You can schedule an
arbitrarily large series of changes (called 'actions'), seeing the effects of
each (within the :class:`~.devicetree.DeviceTree` instance) as it is scheduled.
Nothing is written to disk, however, until you execute the actions.
Expand Down Expand Up @@ -84,7 +84,7 @@ To make changes to the configuration you'll schedule actions, but
At this point, the StorageDevice representing sda3 is no longer in the tree.
That means you could allocate a new partition from the newly free space if you
wanted to (via blivet, that is, since there is not actually any free space on
the physical disk yet -- you haven't commited the changes). If you now ran the
the physical disk yet -- you haven't committed the changes). If you now ran the
following line::

sda3 = b.devicetree.get_device_by_name("sda3")
Expand Down
4 changes: 2 additions & 2 deletions misc/install-test-dependencies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -132,9 +132,9 @@
state: present
name:
- python3-blockdev
- libblockdev2
- libblockdev3
- libblockdev-plugins-all
- gir1.2-blockdev-2.0
- gir1.2-blockdev-3.0
- python3-bytesize
- python3-selinux
- python3-pyudev
Expand Down
3 changes: 0 additions & 3 deletions tests/pylint/runpylint.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,14 @@ def __init__(self):
self.pylintrc_path = os.path.join(current_dir, "pylintrc")

self.false_positives = [
FalsePositive(r"Catching an exception which doesn't inherit from (BaseException|Exception): (BlockDev|DM|Crypto|Swap|LVM|Btrfs|MDRaid|Utils|G)Error$"),
FalsePositive(r"Instance of 'int' has no .* member"),
FalsePositive(r"Method 'do_task' is abstract in class 'Task' but is not overridden"),
FalsePositive(r"Method 'do_task' is abstract in class 'UnimplementedTask' but is not overridden"),
FalsePositive(r"No value for argument 'member_count' in unbound method call$"),
FalsePositive(r"No value for argument 'smallest_member_size' in unbound method call$"),
FalsePositive(r"Parameters differ from overridden 'do_task' method$"),
FalsePositive(r"Bad option value '(subprocess-popen-preexec-fn|try-except-raise|environment-modify|arguments-renamed|redundant-u-string-prefix)'"),
FalsePositive(r"Instance of '(Action.*Device|Action.*Format|Action.*Member|Device|DeviceAction|DeviceFormat|Event|ObjectID|PartitionDevice|StorageDevice|BTRFS.*Device|LoopDevice)' has no 'id' member$"),
FalsePositive(r"Instance of 'GError' has no 'message' member"), # overriding currently broken local pylint disable
FalsePositive(r"Module '(gi.repository.Gio|gi.repository.GLib)' has no .* member"), # pylint/astroid has issues with GI modules https://github.com/PyCQA/pylint/issues/6352
FalsePositive(r"No name '.*' in module 'libmount'")
]

Expand Down
6 changes: 6 additions & 0 deletions tests/skip.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,9 @@
# - all "skips" can specified as a list, for example 'version: [10, 11]'

---

- test: storage_tests.devices_test.md_test.MDTestCase
skip_on:
- distro: "centos"
version: "9"
reason: "MD tests are randomly failing on RHEL/CentOS 9"

0 comments on commit c8fa34f

Please sign in to comment.