Just like all other calculators written in C++, such as this one, the maximum input/output number that such a script can handle is around 10308, the limit of C++ integer values, if exceeded, digit overflowing occurs and the calculator will represent the number as infinity (i.e. the flipped 8 symbol).
Make sure your numerator & denominator is both less than 308 digits long in base-10, if one of them is over this limit in your fraction, that one will appear as infinity, while the other number will be fine. If both of them are over the limit, it will simply show infinity/infinity. Be careful not to exceed the calculators limits!