getcontext().prec causes Spyder to freeze up
See original GitHub issueDescription
What steps will reproduce the problem?
from decimal import * getcontext().prec = 1 b = Decimal(0.1) + Decimal(0.2)
Versions
- Spyder version: 4.0.1
- Python version: 3.7.6
- Qt version: 5.9.6
- PyQt5 version: 5.9.2
- Operating System: Windows 10
Dependencies
atomicwrites >=1.2.0 : 1.3.0 (OK)
chardet >=2.0.0 : 3.0.4 (OK)
cloudpickle >=0.5.0 : 1.3.0 (OK)
diff_match_patch >=20181111 : 20181111 (OK)
intervaltree : None (OK)
IPython >=4.0 : 7.12.0 (OK)
jedi =0.14.1 : 0.14.1 (OK)
nbconvert >=4.0 : 5.6.1 (OK)
numpydoc >=0.6.0 : 0.9.2 (OK)
pexpect >=4.4.0 : 4.8.0 (OK)
pickleshare >=0.4 : 0.7.5 (OK)
psutil >=0.3 : 5.6.7 (OK)
pygments >=2.0 : 2.5.2 (OK)
pylint >=0.25 : 2.4.4 (OK)
pyls >=0.31.2;<0.32.0 : 0.31.7 (OK)
zmq >=17 : 18.1.1 (OK)
qdarkstyle >=2.7 : 2.8 (OK)
qtawesome >=0.5.7 : 0.6.1 (OK)
qtconsole >=4.6.0 : 4.6.0 (OK)
qtpy >=1.5.0 : 1.9.0 (OK)
rtree >=0.8.3 : 0.9.3 (OK)
sphinx >=0.6.6 : 2.4.0 (OK)
spyder_kernels >=1.8.1;<2.0.0: 1.8.1 (OK)
watchdog : None (OK)
cython >=0.21 : 0.29.15 (OK)
matplotlib >=2.0.0 : 3.1.3 (OK)
numpy >=1.7 : 1.18.1 (OK)
pandas >=0.13.1 : 1.0.1 (OK)
scipy >=0.17.0 : 1.4.1 (OK)
sympy >=0.7.3 : 1.5.1 (OK)
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (5 by maintainers)
Top Results From Across the Web
Spyder freeze after code execution · Issue #13114
Spyder seems to freeze on IPython execution of any command for 10 seconds. That includes variable assignment ( x = 10 ) and...
Read more >Python Decimal not accepting getcontext() precision ...
1 Answer 1 · If you have just started Jupyter, getcontext().prec = x behaves normally. · If you use Run > "Run All...
Read more >How to Round Numbers in Python
So, round() rounds 1.5 up to 2 , and 2.5 down to 2 ! ... To change the precision, you call decimal.getcontext() and...
Read more >fr2.rpmfind.net/linux/opensuse/ports/ppc/tumblewee...
(#14243) - Fix a bug introduced in Synapse 1.60.0 which caused an error to be logged when Synapse received a SIGHUP signal if...
Read more >(PDF) Learning Python 5E | Percy Crisologo
This edition has been brought up to date with Python releases 3.3 and 2.7, ... decimal.getcontext().prec = 4 # Fixed precision >>> decimal....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thank you. I apologize for the lack of response. I was not able to update Spyder on my system since I don’t have admin privileges. Thank you for your help.
– Betty J. Greene deciBel Research, Inc. 325 Bob Heath Drive Huntsville, AL 35806 bgreene@dbresearch.netmailto:bgreene@dbresearch.net 256-716-0787
From: Edgar Andrés Margffoy Tuay notifications@github.com Sent: Thursday, September 24, 2020 2:46 PM To: spyder-ide/spyder spyder@noreply.github.com Cc: Greene, Betty bgreene@dbresearch.net; Mention mention@noreply.github.com Subject: [External] - Re: [spyder-ide/spyder] getcontext().prec causes Spyder to freeze up (#13106)
CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.
I’m closing this issue because there wasn’t a follow-up response after more than a week. If your error persists please re-open this issue and reply with the requested information. Thanks for reporting!
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://usg02.safelinks.protection.office365.us/?url=https%3A%2F%2Fgithub.com%2Fspyder-ide%2Fspyder%2Fissues%2F13106%23issuecomment-698551560&data=02|01||64022d26e86047e57c2e08d860c28b2e|58b2fee56a6c4214901fb8d939d90936|0|0|637365735970716115&sdata=J6HN8CE8quBchVLxUsCL9CHyW2NA8Bisq6T%2BsD2kRT4%3D&reserved=0, or unsubscribehttps://usg02.safelinks.protection.office365.us/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAQCQFDCUWJVE5UXE3QBGLSDSHOOZVANCNFSM4OIUQYAA&data=02|01||64022d26e86047e57c2e08d860c28b2e|58b2fee56a6c4214901fb8d939d90936|0|0|637365735970716115&sdata=3PJgHUpQ%2FLgRh0gbgPxXmqomLXkwGmC8DA6%2Fuj7PMl0%3D&reserved=0.
The information contained in this e-mail and any attachments from deciBel Research may contain confidential and/or proprietary information, and is intended only for the named recipient to whom it was originally addressed. If you are not the intended recipient, any disclosure, distribution, or copying of this e-mail or it’s attachments is strictly prohibited. If you have received this e-mail in error, please notify the sender immediately by return e-mail and permanently delete the e-mail and any attachments.
I’m closing this issue because there wasn’t a follow-up response after more than a week. If your error persists please re-open this issue and reply with the requested information. Thanks for reporting!