omz:forum

    • Register
    • Login
    • Search
    • Recent
    • Popular
    1. Home
    2. Richard
    3. Posts

    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.


    • Profile
    • Following 0
    • Followers 0
    • Topics 2
    • Posts 5
    • Best 0
    • Controversial 0
    • Groups 0

    Posts made by Richard

    • Pythonista crashes after returning from share extension APP

      Hi,
      Thanks for the brilliant Pythonista 2.0, the appex and dialogs module are awesome.
      After playing with them for a while, I found returning from some APP may cause Pythonista crash. Bellow is the code:

      # coding: utf-8
      
      import ui
      import dialogs
      
      def button_action(sender):
      	dialogs.share_text('test')
      	
      v = ui.View(frame=(0,0,200,400))
      btn = ui.Button(title='button')
      btn.action = button_action
      btn.center = v.center
      v.add_subview(btn)
      
      if ui.get_screen_size()[1] >= 768:
      	# iPad
      	v.present('popover')
      else:
      	# iPhone
      	v.present(style='full_screen', hide_title_bar=False, orientations=['portrait'])
      

      In the sharing dialog, choose an APP named "youdao dictionary"(An English-Chinese dictionary). The APP will show the dictionary item. Stay for a few seconds and click the OK button to return. Now Pythonista crashes.
      I just tested 2 APPs, OALD and youdao dictionary. OALD is OK.

      posted in Pythonista
      Richard
      Richard
    • RE: URL scheme is not working

      @omz Thanks for the information. That should be the cause.

      posted in Pythonista
      Richard
      Richard
    • RE: URL scheme is not working

      @ccc Thanks. I tried the code on my friend's IOS9.2 IPhone, it also worked.
      Tried to uninstall Pythonista and reinstall, with no luck. I even reseted my phone's settings, still with no luck.
      Notice there is change on URL scheme on IOS9:Querying URL Schemes With canOpenURL.
      With bellow code:

      import webbrowser
      print webbrowser.can_open('pythonista://')
      webbrowser.open('pythonista://')
      

      I got False result to any known URLs. Seems the result matches with that been told in the link.
      I remember I used a loop to check 'com.slovoed.api.%d' % i URL some time ago. This may cause False result of webbrowser.can_open(), but it should not cause webbrowser.open() fail.

      posted in Pythonista
      Richard
      Richard
    • RE: URL scheme is not working

      @ccc May I have your Pythonista version, IOS version and device type? Thanks

      posted in Pythonista
      Richard
      Richard
    • URL scheme is not working

      When I am running below code under IOS 9.2, I can't make quora run:
      import webbrowser
      webbrowser.open('quora://')

      I tried 'quora://' in Launcher, it worked. So the URL should be right.
      I remembered long ago(maybe IOS 8.x, not sure) the URL scheme worked.
      I'm using Pythonista 1.5 on iPhone 6S.
      Will anybody help? Thanks

      posted in Pythonista
      Richard
      Richard