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.
What what what!! New version in TestFlight!!!
-
Pythonista 3 3.4 (340006) is ready to test on iOS. What to Test: New in 3.4: * Support for Python 3.10 * Removed Python 2.7 support * Shortcuts integration: You can now use Pythonista scripts as actions in Apple's Shortcuts app, without launching the app. * Improved documentation with modernized layout, dark mode, and additional content about third-party libraries. * Added pandas and updated various other third-party modules to more recent versions. Please see "What's New in Pythonista" in the in-app documentation for more detailed release notes.
-
https://testflight.apple.com/v1/app/1085978097?build=102223475
I won't be able to install it until next week -- I opened my drawer today and my ipad had swollen to 4 inches thick (battery swelled)
-
@JonB Yes,it has been for 3 year since last updated.
-
Great news!! Thanks @omz
-
-
@omz I'm using Pythonista for years. Thank you for the new Beta and your hard work. I can use Pythonista now for some more time.
My problem is using stash with the beta. But this is not your part. I've open a new issue on the stash GitHub page. Maybe someone can help out.
-
Great news! Thanks @omz!
And seems already submitted 7 Dec, hence 48 days remaining of 3-months TestFlight period. Whatever, itโs downloading and I look forward to more modern Python features
-
@JonB That's we call a very good surprise. Welcome back @omz
Thanks for the welcome, everyone, and great to see you here, @cvp. I'm aware of your situation, and I fully understand if you need to focus on your health right now, but it's nevertheless great to see you helping people with Pythonista so relentlessly. I recently looked at the forum stats and saw that you are the member with (by far) the largest number of posts, and I can't say I was truly surprised because it's been amazing what you've been contributing to this community over the years, and I just want to say that I'm very grateful for that. ๐
And seems already submitted 7 Dec, hence 48 days remaining of 3-months TestFlight period.
Yes, the build is not brand-new. It was rejected by Apple's beta review twice, and then I didn't feel like dealing with this over the holidays, but I managed to sort it out with a friendly letter. :)
-
@omz you are too kind. I have to say that thanks to Pythonista, and therefore thanks to you, my retirement hours have been much more enjoyable and felt shorter.
-
@gurtler_marcel there is a PR request to fix the stash issues -- it is really a few line fix, so you may also be able to just do it manually. I was also getting a hard crash when launching stash, which I solved by wrapping the stash._launch(ns.command) into a function called on ui.in_background, since it seemed like a race condition between the stash ui getting displayed and the editor window moving over...
-
@JonB
Yeah I know. I've created the PR ;)! -
@omz In my Pythonista_startup.py, I use an old code of @JonB to create my own tools button.
Part of code isw=ObjCClass('UIApplication').sharedApplication().keyWindow() main_view=w.rootViewController().view() def get_toolbar(view): #get main editor toolbar, by recursively walking the view sv=view.subviews() for v in sv: if v._get_objc_classname().startswith(b'OMTabViewToolbar'): return v tb= get_toolbar(v) if tb: return tb def create_toolbar_button(action,image,index=0): assert(callable(action)) tb=get_toolbar(main_view) global __persistent_views try: __persistent_views except NameError: __persistent_views={} #check for existing button in this index and delete if needed remove_toolbar_button(index) btn = ui.Button() #btn.frame = (tb.size().width - tb.rightItemsWidth()-(index+1)*40,22,40,40) btn.frame = (tb.size().width - 210,22,40,40) btn.flex='L' btn.image=ui.Image.named(image) if btn.image: btn.image = btn.image.with_rendering_mode(ui.RENDERING_MODE_ORIGINAL) else: btn.image = ui.Image.named('iob:alert_circled_32') btn.action=action btn_obj=ObjCInstance(btn) __persistent_views[index]=(btn,action) on_main_thread(tb.superview().superview().addSubview_)(btn_obj) # in front of all buttons return btn def remove_toolbar_button(index): global __persistent_views try: btn,action = __persistent_views.pop(index) btn.action= None on_main_thread(ObjCInstance(btn).removeFromSuperview)() except KeyError: pass
With the beta version, Pythonista crashes at start.
Starting in Safe mode allows to check content of _objc_exception.txt:The app was terminated due to an Objective-C exception. Details below: 2023-01-20 13:45:16.459902 Modifications to the layout engine must not be performed from a background thread after it has been accessed from the main thread.
After some tests, I've found that calling two functions in main_tread solve the problem.
Good to know for all or beta's bug?on_main_thread(tb.superview().superview().addSubview_)(btn_obj) # in front of all buttons on_main_thread(ObjCInstance(btn).removeFromSuperview)()
-
@cvp I think this was always the rule, which we were allowed to violate for some reason in the past. IIRC, the compiler has certain strictness flags that you can enable to find bugs when doing things in an unsafe way. Presumably the TF version is just being more strict.
-
@omz is alive?! Yippie!!!!! I have reluctantly tried Pyto and was in grief that Pythonista slowly dies. Pythonista is the best thing that can happen to iPhones and ipads.
-
I think the difference is because the beta was built with the iOS 16 SDK, which is apparently stricter about this. I might need to modify a couple of methods in the
ui
module to enforce running on the main thread, but in general, it's often a good idea to use@on_main_thread
for UI stuff. -
Is there a new build number? Using this link https://testflight.apple.com/v1/app/1085978097?build=102223475, I get an error message "This build is not longer available"
-
@omz TestFlight beta is full, see this comment https://github.com/jellyfin/Swiftfin/issues/628#issuecomment-1312826364 on how to remove people who accept beta but donโt use the app
-
@betafull There should be about 200 slots available now. Here's the TestFlight link:
-
@omz just checked about the twitter issues with login and saw this post. This is so fresh! So happy that I can keep using the pythonista app to teach my students.
I am curious how you will implement SwiftUI into your amazing app ๐
(Formerly farmerPaco now happily bigTanuki with a fresh new account)
-
@omz Many of us have abandoned twitter. Is there a mastodon @handle for pythonista or omz we can follow for updates?