datasize icon indicating copy to clipboard operation
datasize copied to clipboard

formatting 'B' from large 'MB' is wrong

Open aphor opened this issue 8 years ago • 1 comments

'{0:a}'.format(DataSize('14796MB'))
>>> '13.779849GiB'
'{0:B}'.format(DataSize('14796MB'))
>>> '14796000000EB'

should look more like

'{0:B}'.format(DataSize('14796MB'))
>>> '14796000000B'

aphor avatar Dec 06 '16 22:12 aphor

  1. add this to test coverage
  2. fix

aphor avatar Dec 06 '16 22:12 aphor