[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: On robustness of maintainer scripts



* Steve Langasek <vorlon@debian.org>, 2013-05-13, 12:21:
why not generate maintainer scripts without pycompile at all? I wanted to delegate as much as possible to interpreter packages, but your idea with temp. files is even better - maintainer scripts can look like this:

| touch /usr/lib/pythonX.Y/dist-packages/namespace/__init__.py¹
| touch /usr/lib/pythonX.Z/dist-packages/namespace/__init__.py¹

| dpkg -L <package> | grep \.py$ | while read file
| do
| 	echo "${file}" >> /var/lib/python/pyX.Ycompile.todo
| 	echo "${file}" >> /var/lib/python/pyX.Zcompile.todo
| done

The disadvantage is that the more logic is included directly in the maintainer scripts, the harder it is to fix any bugs with that logic because every package that includes the buggy behavior needs to be fixed. Even if that's only a simple rebuild with an updated version of dh_python2, it's quite costly to do that over all the affected packages in the archive.

Hear, hear. We had a Python helper that put too much logic directly into maintainer scripts once: it was python-central in lenny. Don't let such a disaster happen again. Thanks. :)

--
Jakub Wilk


Reply to: