See http://bugs.debian.org/427403. The issue can be reduced to a simple example:
gpg --expert --batch --sign-key 'XXXXXXXX'
Now if the UID for example has an expiration date, gnupg asks the user, if he
really wants to sign the key. Now the OP wants to use this in a script and
expected, that the --expert switch will turn of this question (like a force-yes).
Can/should --expert turn off such questions? Might it be worth to implement some
kind of --force-yes option, if the --expert switch is not the right one to
suppress enquiry calls?