I came across the following seemingly bizarre behavior (this is a test case showing the basic issue).
from sympy import *
dz = symbols('dz')
f = 1/(dz - (1.0+I))
f1.series(dz,0,1)
this gives an error like "TypeError: gmpy.mpq() expects numeric or string argument"
On the other hand if I change 1.0 to just 1:
from sympy import *
dz = symbols('dz')
f = 1/(dz - (1+I))
f1.series(dz,0,1)
it gives the correct answer. Can someone explain me why?