
This issue trackerhas been migrated toGitHub, and is currentlyread-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.
Created on2019-12-10 09:48 byArtem Tepanov, last changed2022-04-11 14:59 byadmin. This issue is nowclosed.
| Messages (7) | |||
|---|---|---|---|
| msg358175 -(view) | Author: Artem Tepanov (Artem Tepanov) | Date: 2019-12-10 09:48 | |
Why I can't execute this code:while False: if False: breakprint('WTF?')When I use repl.it or PyCharm on my work (Python 3.7) all works fine, yes I know this code looks silly, but it is a legal expression.About CPython Interpreter:C:\WINDOWS\system32>pythonPython 3.8.0 (tags/v3.8.0:fa919fd, Oct 14 2019, 19:37:50) [MSC v.1916 64 bit (AMD64)] on win32Type "help", "copyright", "credits" or "license" for more information. | |||
| msg358176 -(view) | Author: Steven D'Aprano (steven.daprano)*![]() | Date: 2019-12-10 09:56 | |
I don't know, why *can't* you execute that code? It works fine for me. Although I'm not using the exact same version of 3.8 that you are using.Could you copy and paste (not a screen shot or photo!) the text of your interactive session, including the error that you get, please? | |||
| msg358177 -(view) | Author: Artem Tepanov (Artem Tepanov) | Date: 2019-12-10 10:40 | |
Using cmd:C:\Users\ATepanov>python -VPython 3.8.0C:\Users\ATepanov>python C:\Users\ATepanov\Desktop\Outside_The_Loop.py File "C:\Users\ATepanov\Desktop\Outside_The_Loop.py", line 3 break ^SyntaxError: 'break' outside loopIn Interactive:Python 3.8.0 (tags/v3.8.0:fa919fd, Oct 14 2019, 19:37:50) [MSC v.1916 64 bit (AMD64)] on win32Type "help", "copyright", "credits" or "license" for more information.>>> while False:... break... File "<stdin>", line 2SyntaxError: 'break' outside loop>>> | |||
| msg358178 -(view) | Author: Artem Tepanov (Artem Tepanov) | Date: 2019-12-10 10:44 | |
Python 3.8.0 (tags/v3.8.0:fa919fd, Oct 14 2019, 19:37:50) [MSC v.1916 64 bit (AMD64)] on win32Type "help", "copyright", "credits" or "license" for more information.>>> while False:... if False:... break... File "<stdin>", line 3SyntaxError: 'break' outside loop | |||
| msg358179 -(view) | Author: Karthikeyan Singaravelan (xtreak)*![]() | Date: 2019-12-10 10:49 | |
This seems to be same asissue38640 . Can you please try 3.8.1RC1 to see if it's fixed?https://www.python.org/downloads/release/python-381rc1/ | |||
| msg358180 -(view) | Author: Artem Tepanov (Artem Tepanov) | Date: 2019-12-10 11:07 | |
Thx, after upgrade to:Python 3.8.1rc1 (tags/v3.8.1rc1:b00a2b5, Dec 10 2019, 01:13:53) [MSC v.1916 64 bit (AMD64)] on win32All works fine,...but Could you "pushing the person" which responsible for Web-Site please?, because I got Interpreter from there:https://www.python.org/downloads/release/python-380/Without any Warnings or Recommendation for using 3.8.1rc1Is it normal? | |||
| msg358183 -(view) | Author: Karthikeyan Singaravelan (xtreak)*![]() | Date: 2019-12-10 12:07 | |
Thanks for the confirmation. The issue was found after 3.8.0 release. The fix is in 3.8.1RC1 and will be made as 3.8.1 in couple of weeks. Normally regressions are not listed at downloads page but are tagged as regression in the tracker like the one linked. You can wait for sometime to use 3.8.1 which should fix the issue. | |||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022-04-11 14:59:24 | admin | set | github: 83194 |
| 2019-12-10 12:07:15 | xtreak | set | messages: +msg358183 |
| 2019-12-10 11:07:07 | Artem Tepanov | set | messages: +msg358180 |
| 2019-12-10 10:57:50 | serhiy.storchaka | set | status: open -> closed superseder:while False: break => SyntaxError: 'break' outside loop resolution: duplicate stage: resolved |
| 2019-12-10 10:49:47 | xtreak | set | nosy: +xtreak messages: +msg358179 |
| 2019-12-10 10:44:15 | Artem Tepanov | set | messages: +msg358178 |
| 2019-12-10 10:40:23 | Artem Tepanov | set | messages: +msg358177 |
| 2019-12-10 09:56:00 | steven.daprano | set | nosy: +steven.daprano messages: +msg358176 |
| 2019-12-10 09:48:48 | Artem Tepanov | create | |