Mark existing pytestFlagsArray in args with
`meta.problems.buildPythonPackage-deprecated-pytestFlagsArray`.
Drop the improvised `deprecatedFlagNotEmpty`.
buildPythonPackage and buildPythonApplication now default to
__structuredAttrs = true, so makeWrapperArgs reaches wrapPythonPrograms
as a real bash array. Elements are no longer word-split or
shell-expanded, which breaks three common patterns:
- several arguments packed into one string, such as
"--prefix PATH : ${...}", which makeWrapper rejects with
"makeWrapper doesn't understand the arg ..."
- "\${gappsWrapperArgs[@]}" or "\${qtWrapperArgs[@]}" as list
elements, which also fail the build
- build-time shell variables ($out, $PYTHONPATH, $GI_TYPELIB_PATH, ...)
and shell quoting inside elements. These build fine but end up as
literal strings in the wrapper, e.g. beets got
export GI_TYPELIB_PATH='$GI_TYPELIB_PATH', and gam's --run lines
became single-quoted commands that abort the wrapper.
Split packed strings into one element per argument, append the
gapps/qt wrapper args in preFixup, use placeholder "out" instead of
$out, move other build-time variables into preFixup, and drop the
now-literal quotes.
Also fix the makeWrapperArgs example in the python propagated-inputs
warning.
Assisted-by: Claude Code (Claude Opus 5.5)
Change meta.problems.buildPythonPacakge-internal-* prefix from
`buildPythonPackage: ` to `${finalAttrs.name}: `
The latter is easier to locate,
and the problem name already shows the former.
Add
meta.problems.buildPythonPackage-internal-disabled-overridePythonAttrs
when <pkg>.overridePythonAttrs taking deprecated argument disabled.
buildPythonPackage and buildPythonApplication
still takes argument disabled,
transformed with makeOverridablePythonPackages.
Co-authored-by: Matt Sturgeon <matt@sturgeon.me.uk>
When meta.problems is specified, either by calling buildPythonPackage
or by overriding with <pkg>.overridePythonAttrs,
prioritise the presence of meta.problems.unsupportedPython
over the argument disabled.
Remove overrideStdenvCompat from python-packages-base.nix
Add meta.problems.buildPythonPackage-internal-stdenv
when getting the stdenv argument
to make it an package evaluation error.
Add a test case in tests.overriding
(overridePythonAttrs-deprecated-arg-stdenv)
asserting that the problem appears when overriding with
<pkg>overridePythonAttrs with the deprecated stdenv argument.
Implement the `disabled` argument behaviour with
meta.problems.unsupportedPython
instead of the ugly and buggy `lib.extendDerivation`.
For compatibility purposes,
keep the `passthru.disabled` attribute's overridable with overrideAttrs
while giving higher precedence to direct specification/overriding of
`meta.problems.unsupportedPython`,
making this commit safe to backport.