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.
Pythonista 1.6 Beta
-
@briarfox Do you remember where the text you pasted came from?
-
@omz I was text from lower in the script I was working on. Backspace when used to remove new lines occasionaly crashes as well. Ilm not entirely convinced that it is pythonista. I have reset my ipad air without much luck. I'm testing to see if it's possibly the bt keyboard. However, on the crash the current script loses all changes from when it was initialy opened. Seems to be the only way to save progress is to close pythonista after a few minutes work.
-
@omz Looks like it's my BT Keyboard, Just switched to an old one and no issues. Sorry for the hasty bug report.
Scratch that, Same issue with my other keyboard. Does seem to be caused by the BT keyboard. I have not had it happen with used the on screen keyboard.
-
FYI, sliding open the file browser on the left side saves the script as far as I can tell. There's no need to leave the app or open another file.
-
@omz I emailed the crash report.
-
For what it's worth, I have seen Pythonista crash when editing text files that have non native line endings. I have downloaded a lot of code from various projects on Github and via simple copy paste and occasionally run into source code in the editor that looks like it has an extra space on the ends of lines. I think this means that the lines are cr-lf terminated. Usually you can just clean the text up manually by deleting the extra "spaces" at the ends of the lines. However, doing this with some files can cause Pythonista to crash as you backup (delete) one of these characters. The crashes for these files seem more frequent on blank lines (no text other then the single extra "space"). I avoid these crashes these days largely by avoiding copy pasting code into Pythonista from random websites. I wish I had a sample to provide, but could not find one today.
-
On deleting Carriage Returns causing crashes: http://omz-forums.appspot.com/pythonista/post/5289645013204992 and http://omz-forums.appspot.com/pythonista/post/6431833046646784
-
The following extra modules in Pythonista are not current:
| module | local | PyPI | | name | version | version | | ------------- | -------- | ---------- | | bottle | 0.12.5 | 0.12.8 | | cffi | 0.8.6 | 0.9.2 | | Crypto | 2.6 | 2.6.1 | | distutils | 2.7.4 | | | ecdsa | 0.11 | 0.13 | | html2text | 2014.4.5 | 2015.2.18 | | httplib2 | 0.8 | 0.9 | | jedi | 0.7.0 | 0.8.1 | | jinja2 | 2.7 | 2.7.3 | | markdown | 2.2.0 | 2.6.1 | | markdown2 | 2.2.1 | 2.3.0 | | matplotlib | 1.3.1 | 1.4.2 | | mpmath | 0.18 | 0.19 | | numpy | 1.8.0 | 1.9.1 | | paramiko | 1.13.0 | 1.15.2 | | parsedatetime | 1.3 | 1.4 | | pyflakes | 0.7.3 | 0.8.1 | | pygments | 1.6 | 2.0.2 | | pyparsing | 2.0.1 | 2.0.3 | | PyPDF2 | 1.22 | 1.24 | | pytz | 2013b | 2014.10 | | requests | 2.2.1 | 2.6.0 | | simpy | 3.0.2 | 3.0.6 | | six | 1.6.1 | 1.9.0 | | sqlalchemy | 0.9.7 | 0.9.8 | | sympy | 0.7.4.1 | 0.7.6 | | werkzeug | 0.9.4 | 0.10.1 | | xmltodict | 0.8.7 | 0.9.2 | | yaml | 3.09 | 3.11 | | ------------- | -------- | ---------- |
================
Also, PIL could be updated via Pillow but this would require major surgery.
-
@the_buch Can we have a link to that workflow?
-
@omz latest beta has fixed my crashing issues. I have not had a crash since updating. Thanks!
-
@techteej I can confirm that the Export - Send Email... does not work on iPad. It does work on iPhone though. After "Creating Archive..." the email dialog shows up on iPhone, but it does not on iPad. This is 1.6 (160007).
-
A possible backward compatibility issue. A number of existing scripts that have been written assume that the default bound/frame of ui.View is something large. It now defaults to something relatively small like 100x100. Net result is that the ui of some existing scripts comes up in a tiny box and unusable. This change in default may be a fix to some other problem so this is just an FYI. I have had to fix several scripts to set a proper frame in the init section of their derived view class.
It might be a good idea to add a sample that shows best practice for setting sizes of views based on the devices orientation and ui.get_screen_size() and uses flex attributes.
Also - this is for apps that generate their ui programmatically, not via pui files.
UPDATE: The 'sheet' presentation option has been changed in 1.6 to allow its frame to be user controlled. The default seems to be 100x100 which is different then what it was in past releases.
-
Email export indeed seems to be broken on iPad. Should be relatively easy to fix.
A possible backward compatibility issue. A number of existing scripts that have been written assume that the default bound/frame of ui.View is something large. It now defaults to something relatively small like 100x100.
The default frame/size of
ui.View
actually hasn't changed, but the 'sheet' presentation mode now uses the current size of a view instead of a fixed (larger) size. This is basically a new feature of iOS 8, and while I could effectively disable this, it can be quite useful. The alternative would be to actually change the default frame of new views (which has always been 100x100 for most view types), but this could break other things... -
@omz As for the ui.View thing, putting this in the release notes would help a lot of people, even though it is not a change in the actual app.
-
Having the cb module for BLE is very cool, but I'd like to get the manufacturer specific data while scanning. And the RSSI, and set the scan option to YES. This is for generic advertising BLE peripherals. Also, support for iBeacons would be great -- it is a separate CoreLocation API on IOS.
-
I second @bvwelch's requests. The support for RSSI and a look at iBeacons is going to be required for many appplications. This allows you to get data without having to connect. The other item I would like is providing the peripheral to all the callbacks. This becomes important as soon as you need to support more then one peripheral. It also becomes a performance issue when you have to somehow match data coming out of a characteristic with the peripheral sending the data. It is tricky to do this on the python side since the callbacks are running in multiple threads.
Also - the CentralManager supports state preservation and restoration but you have to ask for it and supply a key to the init procedure. This would be extremely useful for writing a real world app that can be terminated and restarted in a variety of ways. Right now you have to do a complete rescan every time you run your script which can take some time.
-
Is it too late to request TouchID support? At the minimum to replace
keychain.master_password
, but ideally to be able to use within a script. -
Is it too late to request TouchID support? At the minimum to replace keychain.master_password, but ideally to be able to use within a script.
Not sure yet, it's definitely on the roadmap, but might not make it into 1.6.
-
Found a bug that will cause the console to become completely useless.
I have a program that redirects the
sys.stdout
stream to aui.TextField
via the following kind of class:class OutputField (object): def __init__(self, textfield): self.out = textfield def write(self, s): self.out.text += s
I set
sys.stdout = OutputField(v['textfield1'])
and now the console will not do anything; not even autocomplete code. I found a quick fix on my iPhone 6 by simply uninstalling and reinstalling the beta, but I have enough projects on my iPad 3 to make that too impractical at the moment.If anyone has an idea to fix this, that would be greatly appreciated. I gave tried
sys.stdout = sys.__stdout__
, which is supposed to contain the origin system output, but it did nothing.This also effects other projects as well; as nothing will print to the console.
EDIT
After searching frantically around the web, I finally tried restarting Pythonista (I didn't immediately do this at first because it didn't work the first time I tried on my iPhone). Anyways, I found out that saving a reference to stdout is always a good idea.
It's late, I hope this edit helps people in the future.
-
Just wondering, what happens when the beta 'expires'? Does it revert back to 1.5?