gnome-calculator comes up with totally wrong answer

Bug #1680438 reported by Anonymous2
34
This bug affects 6 people
Affects Status Importance Assigned to Milestone
GNOME Calculator
Expired
High
gnome-calculator (Ubuntu)
Triaged
High
Unassigned

Bug Description

Confirmed on:
 - Ubuntu 16.04.1: gnome-calculator version 1:3.18.3-0ubuntu1
 - Ubuntu 16.04.2: gnome-calculator version 1:3.18.3-0ubuntu1.16.04.1

To reproduce the bug (have tried on multiple computers) do something along these lines in the gnome-calculator app:

 - Press 7 and Enter. Screen should show 7 = 7, input field should show 7.
 - Press left arrow and type 12, then the right arrow and type +7. Input field should show 127+7.
 - Press Enter. Screen will show 127+7 = 91, input field will show 91.

No scientific modes or anything; this is in normal mode.

Tags: bionic xenial
Revision history for this message
Anonymous2 (ubuntufrazergazon) wrote :
Revision history for this message
Hans Joachim Desserud (hjd) wrote :

Thanks for taking your time to report this issue and help making Ubuntu better.

I can confirm this issue. I got the same strange result. I also found bug 1687053 but wasn't quite sure whether it should be marked as a duplicate or not.

Changed in gnome-calculator (Ubuntu):
status: New → Confirmed
tags: added: xenial yakkety zesty
removed: gnome-calculator
Revision history for this message
Anonymous2 (ubuntufrazergazon) wrote :

Okay, I think I've found the reason for the issue, and you're right; it is a duplicate. Basically, the calculator is viewing the *new input* and the *last answer* as separate numbers. Since no operator is specified, it is assumed to be multiplication between the two numbers. On this bug, for instance, I type

7

This works normally. 7 = 7; it correctly calculates that. Then I move my arrow key over to type a 12 before the 7 and the arrow keys right to type +7. However, where I am seeing

127 + 7

the calculator is seeing

12 x 7 + 7

Therefore, it calculates that 12 * 7 (84) + 7 = 91. It's the same issue on the duplicate; I'll explain in a comment over there.

Revision history for this message
Sebastien Bacher (seb128) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. The issue you are reporting is an upstream one and it would be nice if somebody having it could send the bug to the developers of the software by following the instructions at https://wiki.ubuntu.com/Bugs/Upstream/GNOME. If you have done so, please tell us the number of the upstream bug (or the link), so we can add a bugwatch that will inform us about its status. Thanks in advance.

Changed in gnome-calculator (Ubuntu):
importance: Undecided → High
Revision history for this message
Pushpendra Kumar (pushpi-gangwar) wrote :
Changed in gnome-calculator:
importance: Unknown → High
status: Unknown → Confirmed
Changed in gnome-calculator (Ubuntu):
status: Confirmed → Triaged
Changed in gnome-calculator:
status: Confirmed → Expired
Revision history for this message
Dave Chiluk (chiluk) wrote :

gnome has moved to gitlab. Corresponding bug is now

https://gitlab.gnome.org/GNOME/gnome-calculator/issues/59

Paul White (paulw2u)
tags: added: bionic
removed: yakkety zesty
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.