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.
Python 3.x Progress Update
-
@JonB l well I got around it by just making sure it didn't go rogue 😜
But honestly, I can force quit Pythonista and restart it quicker than I can type cmds into the console. My iPad Pro is lighting fast, also helps with the animations turned off globally -
you could always create an editor action script that cancels all delays!
-
@ywangd Is the Stash branch py3 still recommended, or is the master release now working well in pythonista 3 using #!python2?
-
@pvanallen i have not gotten around to porting git to handle py3. Also, I don't think there are any py3 only commands -- So #!python2 is currently the best option, unless you want you use the
python
command to run py3 scripts. -
Hi. Is it possible to get onto the beta list ? I have just bought 2.0 and am loving it. I would love to have the Python 3.x version as my 10 year old son is learning Python ATM and the book he is using needs Python 3.x. Please help :)
-
@farscapeone You can use this form to sign up (it might take a couple of days until you actually get an invite, I'm not checking the responses all the time): https://docs.google.com/forms/d/10qRhNIvk7WzcR5_DsQSRNIqLkIqeTYYafbPi9bjj_cw/viewform
-
I'd rather like an ETA, to be honest.
Any idea?
::z::
-
@JonB Thanks for the recommendation - got the standard py2 version installed (which has the #!python2 already in launch_stash.py).
For others, if they want to install the py2 StaSh for py3 in the beta, be sure to switch the Console Interpreter Version to Python 2.7 before you install StaSh. After installing, restart Pythonista and switch back to 3.5 as the interpreter.
Overall, StaSh seems to be working well in the beta. I have seen some cases where Pythonista crashes when using StaSh. It seems to happen when an error message from StaSh is shown in the Pythonista console tab.
Anyway, I used StaSh's pip command to install NLTK and then used nltk.download() in the standard console to install the book corpora (using the default directory worked without needing to explicitly set the NLTK_DATA environment variable). So far, so good!
-
-
@omz not sure if the latest beta broke this, or if it is by design: when running the 2.7 interpreter, after running a script in Documents, site-packages is modified and no longer points to the pythonista3 site-packages.
This got me when installing pyimgur then was unable to import using 2.7 but was able to import with 3.5, or after restarting.
after running script:
private/var/mobile/Containers/Shared/AppGroup/C534C622-2FDA-41F7-AE91-E3AAFE5FFC6B/Pythonista3/Documents', '/private/var/mobile/Containers/Shared/AppGroup/C534C622-2FDA-41F7-AE91-E3AAFE5FFC6B/Documents/site-packages', '/var/mobile/Containers/Bundle/Application/94901C8E-7046-48FC-9BBC-5018FEB83CBF/Pythonista3.app/Frameworks/PythonistaKit.framework/pylib', '/var/mobile/Containers/Bundle/Application/94901C8E-7046-48FC-9BBC-5018FEB83CBF/Pythonista3.app/Frameworks/PythonistaKit.framework/pylib/site-packages', '/var/mobile/Containers/Bundle/Application/94901C8E-7046-48FC-9BBC-5018FEB83CBF/Pythonista3.app/Frameworks/PythonistaKit.framework/pylib/site-packages/PIL_compat']
before
['/private/var/mobile/Containers/Shared/AppGroup/C534C622-2FDA-41F7-AE91-E3AAFE5FFC6B/Documents/site-packages', '/var/mobile/Containers/Bundle/Application/94901C8E-7046-48FC-9BBC-5018FEB83CBF/Pythonista3.app/Frameworks/PythonistaKit.framework/pylib', '/var/mobile/Containers/Bundle/Application/94901C8E-7046-48FC-9BBC-5018FEB83CBF/Pythonista3.app/Frameworks/PythonistaKit.framework/pylib/site-packages', '/var/mobile/Containers/Bundle/Application/94901C8E-7046-48FC-9BBC-5018FEB83CBF/Pythonista3.app/Frameworks/PythonistaKit.framework/pylib/site-packages/PIL_compat', '/private/var/mobile/Containers/Shared/AppGroup/C534C622-2FDA-41F7-AE91-E3AAFE5FFC6B/Pythonista3/Documents/site-packages']
-
@omz Thanks - I have just done that
-
-
@pvanallen You're not the only one, someone else has posted this elsewhere as well, probably in the Slack chat.
-
@farscapeone Thanks, I'll look into it.
-
- The following fails in python 3 ( works in py2). This causes doctests to fail
>>> import editor >>> editor.annotate_line(2) Traceback (most recent call last): File "_ctypes/callbacks.c", line 234, in 'calling callback function' File "/var/mobile/Containers/Bundle/Application/94901C8E-7046-48FC-9BBC-5018FEB83CBF/Pythonista3.app/Frameworks/PythonistaKit3.framework/pylib/site-packages/objc_util.py", line 885, in OMMainThreadDispatcher_invoke_imp retval = func(*args, **kwargs) File "/var/mobile/Containers/Bundle/Application/94901C8E-7046-48FC-9BBC-5018FEB83CBF/Pythonista3.app/Frameworks/PythonistaKit3.framework/pylib/site-packages/editor.py", line 226, in annotate_line filename = os.path.abspath(filename) NameError: name 'os' is not defined
(whoops, i see this was already mentioned)
- The path is not set for .doctests in the same way as py files or py files run as doctests. This is true for both py2 and py3 as far as i can tell. Makes it trickier to write doctests that rely on imports (can still be done via sys.path)
-
Very excited about the Pythonista 3. How do I sign up for beta?
Also, support writing and saving to Google Drive and or Drop Box????
I keep my source code their so I can work on my mac, ipad, surface, or Raspberry Pi.I love Pythonista. It allows me to code at Starbucks on my ipad.
Thank you!!
-
I found now way to rename a python file or to duplicate it in the script editor (beta pythonista)
Move, export, create do work.
-
@omz: Any chance to compile pythonista 2.0 with ipv6 support? AFAIK this should be no major problem.
-
I have been using an app called Working Copy which connects to repositories including github and bitbucket and clones them. Any changes locally can be committed and pushed. So far this has been working great and one of the editors I use Textastic has integrated with it to open files. Anything edited in textastic is updated in Working Copy and can then be pushed to, in my case, bitbucket.
Has there been any thought to integrating pythonista with Working Copy as they already have the repository syncing worked out? It would be great to clone my repository, edit/test/debug, and push from Pythonista :)
Thanks
-