[Piuparts-devel] [Git][debian/piuparts][override-umask] 3 commits: .gitlab-ci: Add reference to new salsaci wrap-and-sort job
Nicolas Dandrimont (@olasd)
gitlab at salsa.debian.org
Fri Mar 15 08:40:12 GMT 2024
Nicolas Dandrimont pushed to branch override-umask at Debian / piuparts
Commits:
1f42c568 by Nicolas Dandrimont at 2024-03-15T09:37:40+01:00
.gitlab-ci: Add reference to new salsaci wrap-and-sort job
- - - - -
25fb4851 by Nicolas Dandrimont at 2024-03-15T09:39:26+01:00
*.py: apply newer black formatting
- - - - -
c94c2a99 by Stefano Rivera at 2024-03-15T09:39:36+01:00
Override umask when creating device nodes
Closes: #1064842
- - - - -
9 changed files:
- .gitlab-ci/salsaci-overrides.yml
- debian/changelog
- master-bin/detect_well_known_errors.py
- piuparts.py
- piupartslib/dependencyparser.py
- piupartslib/dwke.py
- tests/test_dependencyparser.py
- tests/test_piuparts.py
- tests/unittests.py
Changes:
=====================================
.gitlab-ci/salsaci-overrides.yml
=====================================
@@ -46,6 +46,8 @@ test-build-twice:
stage: salsaci/test
test-build-profiles:
stage: salsaci/test
+wrap-and-sort:
+ stage: salsaci/test
variables:
SALSA_CI_REPROTEST_ENABLE_DIFFOSCOPE: 1
=====================================
debian/changelog
=====================================
@@ -1,8 +1,13 @@
piuparts (1.3.1) UNRELEASED; urgency=medium
+ [ Nicolas Dandrimont ]
* Start 1.3.1 development. Use `gbp dch --since=1.3 --multimaint-merge`
to generate a changelog for this release.
+ [ Stefano Rivera ]
+ * Explicitly set the mode on device nodes created by piuparts, overriding
+ umask. (Closes: #1064842)
+
-- Nicolas Dandrimont <olasd at debian.org> Sat, 13 Jan 2024 15:14:04 +0100
piuparts (1.3) unstable; urgency=medium
=====================================
master-bin/detect_well_known_errors.py
=====================================
@@ -43,7 +43,6 @@ class Busy(Exception):
class WKE_Config(piupartslib.conf.Config):
-
"""Configuration parameters for Well Known Errors"""
def __init__(self, section="global", defaults_section=None):
=====================================
piuparts.py
=====================================
@@ -66,7 +66,6 @@ DISTRO_CONFIG_FILE = "/etc/piuparts/distros.conf"
class Defaults:
-
"""Default settings which depend on flavor of Debian.
Some settings, such as the default mirror and distribution, depend on
@@ -119,7 +118,6 @@ class UbuntuDefaults(Defaults):
class DefaultsFactory:
-
"""Instantiate the right defaults class."""
def guess_flavor(self):
@@ -139,7 +137,6 @@ class DefaultsFactory:
class Settings:
-
"""Global settings for this program."""
def __init__(self):
@@ -766,7 +763,6 @@ FileInfo = namedtuple("FileInfo", ["st", "target", "user", "group"])
class Chroot:
-
"""A chroot for testing things in."""
def __init__(self):
@@ -1236,6 +1232,7 @@ class Chroot:
# mounting them individually.
try:
os.mknod(self.name + devname, stat.S_IFCHR | 0o666, devnum)
+ os.chmod(self.name + devname, 0o666) # Override umask
isdevice = True
except OSError as err:
if err.errno != errno.EPERM:
=====================================
piupartslib/dependencyparser.py
=====================================
@@ -32,7 +32,6 @@ import re
class DependencySyntaxError(Exception):
-
"""Syntax error in package dependency declaration"""
def __init__(self, msg, cursor):
@@ -51,7 +50,6 @@ class DependencySyntaxError(Exception):
class _Cursor:
-
"""Store an input string and a movable location in it"""
def __init__(self, myinput):
@@ -120,7 +118,6 @@ class _Cursor:
class SimpleDependency:
-
"""Express simple dependency towards another package"""
def __init__(self, name, operator, version, arch):
@@ -139,7 +136,6 @@ class SimpleDependency:
class DependencyParser:
-
"""Parse Debian package relationship strings
Debian packages have a rich language for expressing their
=====================================
piupartslib/dwke.py
=====================================
@@ -31,7 +31,6 @@ LOG_EXT = ".log"
class Problem:
-
"""Encapsulate a particular known problem"""
required_tags = ["PATTERN", "WHERE", "ISSUE", "HEADER", "HELPTEXT"]
@@ -113,7 +112,6 @@ class Problem:
class FailureManager:
-
"""Class to track known failures encountered, by package,
where (e.g. 'fail'), and known problem type"""
=====================================
tests/test_dependencyparser.py
=====================================
@@ -4,7 +4,6 @@ import piupartslib.dependencyparser
class DependencyParserTests(unittest.TestCase):
-
"""Tests for module dependencyparser."""
def parse(self, str):
=====================================
tests/test_piuparts.py
=====================================
@@ -52,9 +52,10 @@ class DefaultsFactoryTests(unittest.TestCase):
)
def test_new_defaults_panics_with_unknown_flavor(self):
- with patch.object(self.df, "guess_flavor", return_value="centos") as guess_flavor_mock, patch.object(
- piuparts, "panic", side_effect=SystemExit
- ) as panic_mock:
+ with (
+ patch.object(self.df, "guess_flavor", return_value="centos") as guess_flavor_mock,
+ patch.object(piuparts, "panic", side_effect=SystemExit) as panic_mock,
+ ):
with self.assertRaises(SystemExit):
self.df.new_defaults()
=====================================
tests/unittests.py
=====================================
@@ -6,7 +6,6 @@ import piupartslib.packagesdb
class FakeLogDB(piupartslib.packagesdb.LogDB):
-
"""A fake version of the LogDB class, for testing
This version simulates filesystem actions so that there is no need
View it on GitLab: https://salsa.debian.org/debian/piuparts/-/compare/836664432bc1a0c2d11f57b06e5ddb0689fdb80f...c94c2a99fb9215c60434e4713b9b57eb7fcbe048
--
View it on GitLab: https://salsa.debian.org/debian/piuparts/-/compare/836664432bc1a0c2d11f57b06e5ddb0689fdb80f...c94c2a99fb9215c60434e4713b9b57eb7fcbe048
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/piuparts-devel/attachments/20240315/c37f4fb5/attachment-0001.htm>
More information about the Piuparts-devel
mailing list