Package: bash-completion Version: 1:2.10-1 Severity: normal -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256
Hello, I ran into the following error while packaging the latest version of hugo package: dh_bash-completion: error: Cannot resolve variable "${BASH_COMP_DEBUG_FILE}" in debian/hugo.bash-completion (line 5) where debian/hugo.bash-completion is a proper completion snippet. It turns out that the error was triggered when I bumped "debhelper-compat (= 12)" to "debhelper-compat (= 13)" in debian/control. This is a behavioural change in debhelper v13. From debhelper(7): - Many dh_* tools now support limited variable expansion via the ${foo} syntax. In many cases, this can be used to reference paths that contain either spaces or dpkg-architecture(1) values. While this can reduce the need for dh-exec(1) in some cases, it is not a replacement dh-exec(1) in general. If you need filtering, renaming, etc., the package will still need dh-exec(1). Please see "Substitutions in debhelper config files" for syntax and available substitution variables. To dh_* tool writers, substitution expansion occurs as a part of the filearray and filedoublearray functions. dh_bash-completion currently uses filedoublearray() to detect if debian/package.bash-completion is a list of files or not. While it has worked well in the past, it has now become a lot more flakey and error-prone as debhelper v13+ now always attempt such variable substitution. While one could try to work around the issue by changing "${foo}" to "$foo" in the proper completion snippet, quoting variables with curly braces like ${foo} is nonetheless perfectly valid bash syntax, and it is often unavoidable in cases such as "${foo}bar" or "${foo}_bar". Perhaps there are better ways to distinguish whether debian/package.bash-completion is a file list or proper snippet than sending it to filedoublearray() and see if it fails or not? Cheers, Anthony - -- System Information: Debian Release: bullseye/sid APT prefers unstable APT policy: (500, 'unstable'), (1, 'experimental') Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 5.7.0-1-amd64 (SMP w/4 CPU threads) Kernel taint flags: TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE Locale: LANG=en_CA.UTF-8, LC_CTYPE=en_CA.UTF-8 (charmap=UTF-8), LANGUAGE not set Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) LSM: AppArmor: enabled - -- no debconf information -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEFCQhsZrUqVmW+VBy6iUAtBLFms8FAl8SBnIACgkQ6iUAtBLF ms9mWw//V/Z4sOwhrWnHT/L2KTKf5IgiK8k+1PlWL1OQXfpAJxUWXUeBSL07mxlW R3MXl0cef3s7ShvHBpFtJLk19cXWvfeGY8GHtXf3XNxvKCz3kKQsETNZH7BibMqg Npt1ZyfWDwilxTpB8eWJ+ZdBT+vlfi57G1tvhdUEvkmfRw9HU7R0ephySuGCWAdc 3e2NoaI7OyVQ/WzkgcdW44ZeaC4GUkBgoHJiF1E+22K/fgMV95vqyUtr8nh8Kz5q W1Px7CafdDPuMT0vxxMu/YWfVOApRKssKOqoVvxwV1MBzPXCau3AjcHe3Z84W9Tc 6ko3hm9tMUZGUMuaVE+GV11wL+mEfB5u7ZvRG1SADmcyFLR5mjdkgp89LroKe4Dx TQT609B9nPYz85ROTVhDkKR5jOU1CInObTUnlW+g1/xXb/kwyKl/Qt50DfD7Du45 CmDiPEWoc0Ptn9LoXUYO7MoEXit3XyOYJYhOS5jsgqpgvCJjFnpl7IR6jFtPfVGN 0dQDAf7+FXT1CBmaCMevPX9BZnfPpwbbn41lqsoK3eq7IiWCniUtqWVMRGs2OwPV JvOVIFxQsS1ENzU38m4wTQPwGOgmA6Xz1J5FV6j6ItpDS+ZaOvyYXk0Ab9JMb10L 3SaZfv8BbsBIBjtF6zgPqv/cyXTAfIaUwXF/skSgfbE6yf1US1Y= =Ez1T -----END PGP SIGNATURE-----