mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-12-06 04:40:10 +00:00
weblate: Fix compilation and module test (#565943)
This commit is contained in:
@@ -26,8 +26,12 @@ let
|
||||
# Use a settings module in dataDir, to avoid having to rebuild the package
|
||||
# when user changes settings.
|
||||
makeWrapperArgs = (old.makeWrapperArgs or [ ]) ++ [
|
||||
"--set PYTHONPATH \"${settingsDir}\""
|
||||
"--set DJANGO_SETTINGS_MODULE \"settings\""
|
||||
"--set"
|
||||
"PYTHONPATH"
|
||||
settingsDir
|
||||
"--set"
|
||||
"DJANGO_SETTINGS_MODULE"
|
||||
"settings"
|
||||
];
|
||||
})
|
||||
);
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
redisTestHook,
|
||||
fontconfig,
|
||||
nixosTests,
|
||||
fetchpatch,
|
||||
|
||||
# runtime inputs
|
||||
gitSVN,
|
||||
@@ -62,6 +63,20 @@ python3Packages.buildPythonApplication (finalAttrs: {
|
||||
'_cmd: ClassVar[str] = "${lib.getExe gitSVN}"'
|
||||
'';
|
||||
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
name = "typing_improvement"; # a prerequisite for the fix_migration patch
|
||||
url = "https://github.com/WeblateOrg/weblate/commit/df5aa0fd19287feb035eaf02323c72bcce92d1ad.patch";
|
||||
hash = "sha256-oOxCD5/g2XPwXtOKHHiiKV9caITxfoiWTzolwgwZobc=";
|
||||
})
|
||||
(fetchpatch {
|
||||
name = "fix_migration"; # should be included in post-2026.9.1 release
|
||||
url = "https://github.com/WeblateOrg/weblate/commit/7c4235779f89a421c7c6c24ee5bbbaa4f0ab50f1.patch";
|
||||
excludes = [ "docs/changes.rst" ]; # incompatible change
|
||||
hash = "sha256-V8HyeBALZ8HaXHmhC8PK8ktB4osf9za+FH7dFLI3xis=";
|
||||
})
|
||||
];
|
||||
|
||||
build-system = with python3Packages; [ setuptools ];
|
||||
|
||||
nativeBuildInputs = [ gettext ];
|
||||
@@ -343,6 +358,9 @@ python3Packages.buildPythonApplication (finalAttrs: {
|
||||
# djangosaml2idp2 is not packaged yet
|
||||
"weblate/utils/tests/test_djangosaml2idp.py"
|
||||
|
||||
# Some issue related to presumably misconfigured data directory. See #565921 for details.
|
||||
"weblate/fonts/tests/test_models.py::FontModelTest::test_cleanup"
|
||||
|
||||
# Don't understand why
|
||||
"weblate/trans/tests/test_alert.py::WebsiteAlertSettingTest::test_website_alerts_enabled"
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user