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
-
@MartinPacker: Here is a very simple
appex
example script to import a file from a URL in, say, Safari. This one copies files already stored in other apps, like the Mail app. I personally don't have an Apple Watch, so I can't give you any examples on that front. It seems, though, from the documentation of the Apple Watch interface, it just executes scripts and provides text to theraw_input()
function, and nothing more. I might be wrong, but that is all I can gather. -
Thanks @Gerzer.
Actually the Roll Dice python script uses ui but doesn't take input - and works nicely on the watch. If I do more research on that it might yield something.
One difficulty is actually getting scripts off iPad onto iPhone in "Watch" folder. Anyone know how to do it.
The quid pro quo is I'm motivated to work on getting the Watch functionality known - for when 1.6 is shipped. If that's a post (on my blog) or examples that'd be fine.
I should work with @ccc to get something working from the Watch that talks to an IBM mainframe... :-)
(Google me if you think that last is odd.) :-)
-
Ah I see @omz's post. I would think if the ui route, rather than raw_input(), works we'd have a winner.
But obviously your prerogative.
-
The prompt seems to appear AFTER the input is dictated.
The way the current watch "app" beta works is very simple: It can send a request to the iPhone app to start a script, and then it starts polling for events every few seconds (as long as the app is visible on the watch). An event can be text/image console output, or a text input request (
raw_input
). The only way to get text input on the watch is to present a full-screen dictation view (which can include "quick reply" options that are set viaappex.watch
). If you callraw_input
directly after printing, it's quite likely that the two events arrive at the same time on the watch because of the polling interval, so the text input view covers the screen before you see the print output...Obviously, this is pretty inefficient, but I haven't found a better way to handle input/output with the current WatchKit SDK. I'm fairly sure that a better app will be possible when watchOS 2 comes out, but I haven't really looked into it yet.
-
Any estimation for when pythonista 1.6 will be public? Haven't been able to join the beta, and I really wanna use it! A month? Three? A year?
-
Thanks @omz. I can see the current infrastructure makes it tough to make a decent watch-originated app.
I'm wondering if I can use Workflow to front-end an "on the phone" app with a half decent UI.
As it happens I was just playing; I don't have a real application just yet.
-
@webmaster4o same here. I've been trying to be as patient as possible. Hopefully it's soon!
-
Bug: in Editor Actions only the last script shows in the share sheet. Also reported by @GCarver http://omz-forums.appspot.com/pythonista/post/6187778610036736#post-5310158079000576
-
hyshai, I was about to respond that I didn't have this problem.... until I clicked more, and reordered the scripts.... then all but one disappeared. so the symptom appears to be caused once the more menu is entered...
-
@JonB
Oops! Sorry :( -
The unpredictable script clearing bug has returned for me recently and has happened multiple times. The few common circumstances that I could observe were the following:
- I was using an external keyboard
- The files were empty when I reopened the app after it was terminated (either automatically or manually by swiping it out of the app switcher)
- The affected files were the currently active editor tab
- More than one tab was open (not entirely sure about this one)
- None of the files were Python scripts (two Markdown files and one plain text file)
One time this even happened twice in a row. I had about 5 files open, one of them got cleared. I closed that tab, restarted the app, and the next file was cleared as well.
Can't say if this is related to the bug that emptied files when updating to a new beta version. That still happened with the last update, but that was a few weeks ago. I've got a feeling the beta might be expiring again soon. *hint hint*
-
I think I know why this happens now, and it should be fixed in the next build (later this week). Basically, the editor sometimes auto-saves a file even though it hasn't finished loading yet, resulting in an empty file.
In the case of the beta release notes, the app first restores the previous tabs, but then immediately opens the release notes file in the selected tab, before the previous file has actually been loaded completely. Opening a different file (the release notes) in the same tab triggers an auto-save, so the previous file is overwritten with an empty file...
In this case, it's trivial to reproduce, but in other situations, the bug appears to be more "random". It could for example happen if the app goes into the background (triggering an auto-save) while a file is being loaded etc. The fix is pretty simple – just don't save anything before a file is loaded (duh!).
It's possible that there are other reasons for this behavior, but I'm relatively confident that this is it.
-
not sure if this is a bug or feature...
when creating and presenting a ui.View, the default bg color is (0,0,0,1), or black.
however when presenting as panel, the bg color shows up as white, even though the attribute is unchanged.
setting the bg color manually does correct this.
I want to say that in 1.5, the default color was white, but I could be wrong.
-
I can confirm that in 1.5, default
background_color
is(0.0, 0.0, 0.0, 1.0)
.view.present
shows black, butview.present("panel")
shows up white. The same bug exists in 1.5. -
The value that you get from the
background_color
attribute is actually incorrect, it should be either(0.0, 0.0, 0.0, 0.0)
orNone
, i.e. the default color is transparent, which has different effects depending on the presentation style. -
Oh! So there is a bug, but not the one we thought :P
-
What's the word on iOS 9 beta... are there any known 1.6 issues with it? Apple beta software program just sent out notifications and I want to jump in.
Update:
Just went for it and there appears to be a problem with the speech module - specifically speech.get_languages() now returns an empty array rather than the lost of languages and corresponding codes.
PS anybody have any scripts to use as action extensions to get the direct URL of a Flickr photo?
-
The current Beta expires in 21 hours...
-
just click the download button, choose the size, then copy the url
-
In the newest beta, pythonista becomes completely unresponsive if
dialogs.share_image
is called while the keyboard is showing. In my UI, the user puts text into a box, then presses a button that callsdialogs.share_image
. If the user fails to close the keyboard before pressing the button, pythonista doesn't crash, it just freezes. If the keyboard is hidden when the button is pressed, everything works perfectly.#Perfect:
#Broken:
When the keyboard is open, the dialog fails to show, and the app must be quit from multitasking as it is completely unresponsive.