Public bug reported: python3 Math bug: In accordance with IEEE_754-1985, math.sqrt(-1.25) should return NaN, and print function should be able to indicate it.
Demo code: import math c = math.sqrt(-1.25) print(c) When run produces: Traceback (most recent call last): File "./float-test.py", line 4, in <module> c = math.sqrt(-1.25) ValueError: math domain error Should produce: NaN OR: NOT A NUMBER For more information, see https://en.wikipedia.org/wiki/NaN ProblemType: Bug DistroRelease: Ubuntu 20.04 Package: python3 3.8.2-0ubuntu2 ProcVersionSignature: Ubuntu 5.4.0-42.46-generic 5.4.44 Uname: Linux 5.4.0-42-generic x86_64 ApportVersion: 2.20.11-0ubuntu27.6 Architecture: amd64 CasperMD5CheckResult: skip CurrentDesktop: KDE Date: Sat Aug 15 21:30:13 2020 InstallationDate: Installed on 2020-04-26 (112 days ago) InstallationMedia: Kubuntu 20.04 LTS "Focal Fossa" - Release amd64 (20200423) ProcEnviron: PATH=(custom, no user) XDG_RUNTIME_DIR=<set> LANG=en_US.UTF-8 SHELL=/bin/bash SourcePackage: python3-defaults UpgradeStatus: No upgrade log present (probably fresh install) ** Affects: python3-defaults (Ubuntu) Importance: Undecided Status: New ** Tags: amd64 apport-bug focal -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to python3-defaults in Ubuntu. https://bugs.launchpad.net/bugs/1891782 Title: python3 Math bug: In accordance with IEEE_754-1985, math.sqrt(-1.25) should return NaN, and print function should be able to indicate it. Status in python3-defaults package in Ubuntu: New Bug description: python3 Math bug: In accordance with IEEE_754-1985, math.sqrt(-1.25) should return NaN, and print function should be able to indicate it. Demo code: import math c = math.sqrt(-1.25) print(c) When run produces: Traceback (most recent call last): File "./float-test.py", line 4, in <module> c = math.sqrt(-1.25) ValueError: math domain error Should produce: NaN OR: NOT A NUMBER For more information, see https://en.wikipedia.org/wiki/NaN ProblemType: Bug DistroRelease: Ubuntu 20.04 Package: python3 3.8.2-0ubuntu2 ProcVersionSignature: Ubuntu 5.4.0-42.46-generic 5.4.44 Uname: Linux 5.4.0-42-generic x86_64 ApportVersion: 2.20.11-0ubuntu27.6 Architecture: amd64 CasperMD5CheckResult: skip CurrentDesktop: KDE Date: Sat Aug 15 21:30:13 2020 InstallationDate: Installed on 2020-04-26 (112 days ago) InstallationMedia: Kubuntu 20.04 LTS "Focal Fossa" - Release amd64 (20200423) ProcEnviron: PATH=(custom, no user) XDG_RUNTIME_DIR=<set> LANG=en_US.UTF-8 SHELL=/bin/bash SourcePackage: python3-defaults UpgradeStatus: No upgrade log present (probably fresh install) To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/python3-defaults/+bug/1891782/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp