And If you remember, in my previous PR where all these functions were in sympy/core/numbers.py the exact line was 

return [int(y/x) + 1] +Rational(num,denom).egypt_greedy()

It was working fine then .