-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Raw REPL crashing #251
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Your first "while" loop will never exit. It just executes the next 3 lines repeatedly. You need to revise your indentation. |
something more like:
|
Thanks Jerry! Will revise the indentation. To clarify No. 6 and No. 7: I'm not trying to have ampy and screen running at the same time. I could reset the unit , unplug it from power -- and Raw REPL will exhibit the same behaviour as shown in the video. No. 5 when it hangs, I abort the process (Ctrl + C) before opening a screen session. Edit: Folks from the discord server also suggested to check if an instance was running in the background. I was able to recreate the bug and then checked whether or not a screen session was running using |
Ok, so I took a look at this. I don't think its a CircuitPython bug. I think you've found a state where the code in AMPY to get into raw REPL isn't enough. (It does two CTRL-Cs but thats not enough.) Please re-file it here: https://github.com/adafruit/ampy/issues |
It's possible for Raw REPL to stop working properly if
main.py
contains code that looks like what I whipped up below:main.py contents
Normally, I'd get something like:
ampy.pyboard.PyboardError: ('exception', '', 'Traceback (most recent call last):\r\n File "<stdin>", line 14\r\nSyntaxError: invalid syntax\r\n')
but running this
main.py
code through ampy causes terminal to hang.To reproduce
main.py
(hangs)main.py
(works ok!)main.py
through ampy (hangs) *File "/usr/local/lib/python2.7/dist-packages/ampy/pyboard.py", line 202, in enter_raw_repl raise PyboardError('could not enter raw repl') ampy.pyboard.PyboardError: could not enter raw repl
Observed on an ESP8266 running CP 2.0.0-rc.2 / Ubuntu 16
Latest ampy & esptools
I've attached a screen captured video (webm format) demonstrating this issue:
ESP Development Environment-2017-09-12T01-24-24-828588200Z.zip
Here's the error when trying to use ampy when the Raw REPL fails:
What fixes the issue
Re-flash the firmware.
The text was updated successfully, but these errors were encountered: