Welcome!
This is the community forum for my apps Pythonista and Editorial.
For individual support questions, you can also send an email. If you have a very short question or just want to say hello — I'm @olemoritz on Twitter.
Trigger crash
-
Maybe someone can reproduce this behaviour:
Create a simple python script (choosing "Empty script"). Add one line
import matplotlib as plt
and now continue on a new line with "plt.show(". Pythonista immediately crashes on my ipad.
-
Everything ok for me.
-
I also can not replicate this crash in the current Pythonista2 nor in the current Pythonista 3.
I would suggest throwing Pythonista out of RAM and then rebooting Pythonista and retrying.
-
I got the same kind of problem with a little script where I still was busy to write.
Each time I wanted to wanted to deleted last character, crash...
Even if I removed the app from the tasks list.
Finally, I've rebooted my iPad and the problem has disappeared
No trace because no run, not reproductible after reboot and never occurred before or after???? -
Thank's for all the answers so far. I alreadry rebooted the ios several times. Did not help. I also through away the whole file and rewrote it.
-
I removed the whole app and installed it again. Now it seems to work. Unbelievable!
Thank's for you help. I showed me the path to follow.
-
Sorry, I was unclear. My suggestion was not to reboot the iOS and not to throw away the file and not to delete and reinstall Pythonista but instead just to reboot Pythonista: tap once on the Home button and then swipe up on the running Pythonista app to "throw it out of RAM". All is well that ends well.
-
@ccc As I said, I have had the same kind of problem, of course not exactly THE same because not the same script, but I removed the app from the tasks list (4/5 fingers up, Pythonista swipe up) then the RAM was cleaned, and that without success. I've had to reboot the iPad (thus the iOS) to solve the problem, but I didn't need to reinstall Pythonista. I think to reinstall an app is "passive" action, but to close an app (one tape on home or 4/5 fingers zoom-like movement, remove an app from the RAM and reboot the iPad are "active" actions, that will say "active on the RAM".
-
I did it. But did not help.
-
This is a known bug (on the tracked list#11). It seems to affect the py2.7 interpreter in pythonista 3.0, when autocompleting matplotlib objects. It sometimes takes a long time, but when jedi gets around to finishing import of matplot lib, it crashes.
Workarounds:
- Use the 3.x interpreter as default, and do not shebang the interpreter. if you really want to use py2, you can longpress the run button. (note shebang does not take effect immediately, you may need to close and reopen the file if you have shebang'd it to python2)
- Never type a period after a matplotlib variable or package name. Instead, type a space, then a period, then after you have a fully formed expression, go back and erase the spaces...obviously difficult to remember to do!
- there is an probably a objc way to turn off extended completion... swizzling setFallbackCompletionProvider_ of OMBasicPythonCompletionProvider to do nothing might work.
- . I tried setting the nsuserdefaults that correspond to completion, but these don't seem to do anything anymore.
edit: item 3 works.
install https://github.com/jsbain/objc_hacks.git
then install disableJEDI as a wrench action.
This will disable jedi completions until you restart pythonista -
Thank's for the explanation and workaround. I switched to version 3.