I guess this is a bug in the standard ihooks module. import ihooks ihooks.install() import fcntl loads the deprecated version.