python-deltasigma icon indicating copy to clipboard operation
python-deltasigma copied to clipboard

AttributeError: module 'fractions' has no attribute 'gcd'

Open nishanchettri opened this issue 1 year ago • 2 comments

Please solve this error

nishanchettri avatar May 30 '23 15:05 nishanchettri

I fixed by replacing with math.gcd

from math import gcd

#gcd = fractions.gcd

lswang2 avatar Aug 04 '23 08:08 lswang2

In case anyone is looking for a quick workaround, I monkeypatched the import like:

import fractions, math
fractions.gcd = math.gcd # hack to fix deltasigma import

import deltasigma

ljmatkins avatar Nov 12 '23 23:11 ljmatkins