omz:forum

    • Register
    • Login
    • Search
    • Recent
    • Popular

    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.


    Xcode Template for Pythonista

    Pythonista
    29
    68
    65706
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • TheRealBret
      TheRealBret last edited by

      I really want to have a new Xcode template for Pythonista 3. I realize that I've already bought Pythonista so I'm not generating new income for @omz.... so I hereby pledge to send money via Paypal/Zelle (or any other method) to @omz to help support his time for the production of a new Xcode template. I'd gladly pay $25 for a new template. I'd even pay this annually if it would be updated regularly.

      Thoughts anyone? @omz?? How can we help get a new Xcode template made?

      vignesh 1 Reply Last reply Reply Quote 0
      • vignesh
        vignesh @TheRealBret last edited by

        @TheRealBret Good news!
        @omz said:

        Here's a first attempt at a Python 3-based Xcode template: https://www.dropbox.com/s/5l94m0xjbot5je0/Pythonista3AppTemplate.zip?dl=1

        This is roughly equivalent to the current App Store version (not the 3.3 beta), and not final, just something to play around with for people interested in the Xcode template. Let me know if anything's unclear.

        1 Reply Last reply Reply Quote 0
        • TheRealBret
          TheRealBret last edited by

          Indeed - I’m very happy to see the new template. Thank you!

          My offer still stands - I would like a way to give a donation to @omz to help offset continued development of Pythonista. I can’t see how my payment a year ago is helping today.

          eliotradisa 1 Reply Last reply Reply Quote 0
          • vignesh
            vignesh last edited by

            Is it possible for someone to upload a version of the template for python3 with the fix to include the line at the top of all the files already done? I am having lots of trouble doing it myself.

            1 Reply Last reply Reply Quote 0
            • ruohola
              ruohola last edited by ruohola

              Any update on the template? As of April 2020 the template is completely broken since it uses the deprecated UIWebView API which is not allowed anymore: https://forum.omz-software.com/topic/6474/python3-xcode-template-broken-because-of-deprecated-uiwebview

              1 Reply Last reply Reply Quote 0
              • JonB
                JonB last edited by

                Is the binary signed in some way? I wonder if you were to edit it in a hex editor, and replace UIWebView with some other nonsense class name (same number of characters).
                Since objc is message based, there is nothing linked to support UIWebView, just a runtime call with a c string with the classname. As long as you never instantiate a webview, things won't crash.

                1 Reply Last reply Reply Quote 2
                • eliotradisa
                  eliotradisa @TheRealBret last edited by

                  This post is deleted!
                  1 Reply Last reply Reply Quote 0
                  • eliotradisa
                    eliotradisa last edited by eliotradisa

                    This post is deleted!
                    1 Reply Last reply Reply Quote 0
                    • coltonboyd
                      coltonboyd last edited by

                      @ruohola sorry this is a little late and I hope this information is still relevant for you. I took @JonB 's advice and went into the P3kit framework and edited the P3kit file. For me it popped up as a unix executable, so I needed to download a hex editor to go in and modify it.

                      All I did was command-F and find all the instances of UIWebView and replace them all with UIBarItem. This is an API with the same character length and the API isn't deprecated. Save the file and make sure it is still in your project directory.

                      I archived and uploaded my build last night and the App Store did not reject the build. so this is a good working solution. My app is a 2D shooting game called Flyboy Adventure Game and it is currently under beta review as we speak. I've tested my game on Testflight and it works great, so hopefully there is no long term repercussions from using this workaround.

                      mikael JonB 2 Replies Last reply Reply Quote 1
                      • mikael
                        mikael @coltonboyd last edited by

                        @coltonboyd, thanks for sharing, this is great news. I am (again) tempted to put something to the App Store.

                        1 Reply Last reply Reply Quote 1
                        • coltonboyd
                          coltonboyd last edited by

                          @mikael

                          Of course, just for reference the Hex editor I used was SlickEditPro2019. You can download a free trial and it’s pretty easy to use.

                          I’m currently trying to upload a updated Pythonista 3 Template to my Dropbox but it’s taking forever.

                          1 Reply Last reply Reply Quote 0
                          • JonB
                            JonB @coltonboyd last edited by

                            @coltonboyd It might be good if you could document the various steps you went through from start to end -- for instance did you have to do the workaround so file doesn't flag .py files as executable? Anything else you had to modify from the template?

                            1 Reply Last reply Reply Quote 0
                            • coltonboyd
                              coltonboyd last edited by

                              @JonB I’m glad you mentioned that. I forgot to inform that to get past signing errors I used @RomSpy ’s last template he posted from this forum link:

                              https://forum.omz-software.com/topic/5837/xcode-template

                              After getting past the signing errors is when I started getting the UIWebView deprecated rejections from Apple. That is when I stumbled upon this forum post and tried out your idea of downloading the hex editor, etc. I first tried replacing UIWebView with WKWebView like Apple suggested, but it ended up crashing my app after launch. Replacing it with UIBarItem had no effect.

                              Here is my latest version of the Pythonista 3 App Template that I used for my game I’m currently publishing to the App Store as we speak.

                              https://www.dropbox.com/s/442v3cp90oyk8rd/Pythonista3AppTemplate Updated .zip?dl=0

                              1 Reply Last reply Reply Quote 1
                              • vovaburm
                                vovaburm last edited by

                                @coltonboyd said:

                                Thanks! But it seems that you upload version with WKWebView. I changed that to UIBarItem and it worked

                                1 Reply Last reply Reply Quote 0
                                • coltonboyd
                                  coltonboyd last edited by

                                  @vovaburm oops I must have uploaded the wrong version then off my desktop, my bad! I’m glad you got it to work!

                                  1 Reply Last reply Reply Quote 0
                                  • coltonboyd
                                    coltonboyd last edited by

                                    To anybody that needs it, here is the correct and updated Pythonista 3 Template:

                                    https://www.dropbox.com/h?preview=Pythonista3AppTemplate+Updated+.zip

                                    1 Reply Last reply Reply Quote 2
                                    • Ichicoro
                                      Ichicoro last edited by

                                      @coltonboyd the last link you posted doesn't work :(

                                      1 Reply Last reply Reply Quote 0
                                      • ltddev
                                        ltddev last edited by ltddev

                                        Yes, @coltonboyd, I too cannot access this link but I would very much like to use your Python 3 Pythonista 3 template for Xcode. Could you please post a corrected link?

                                        1 Reply Last reply Reply Quote 0
                                        • coltonboyd
                                          coltonboyd last edited by

                                          @Ichicoro lol I hate myself. This should work, let me know if it doesn’t.

                                          https://www.dropbox.com/s/nq899u5gv54o5t8/Pythonista3AppTemplate Updated .zip?dl=0

                                          dustlancer 1 Reply Last reply Reply Quote 1
                                          • ritanari31
                                            ritanari31 @JonB last edited by

                                            This post is deleted!
                                            1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post
                                            Powered by NodeBB Forums | Contributors