• @JonB your statment on alias is correct 😃

    But in this case we are speaking of Scene module importing ui and then Developer using ui module through scene with without making a separate import of ui in active script where __name__=="__main__"

    Inside scene.py ...

    from _scene2 import * import _scene2 from scene_drawing import * import math from numbers import Number from io import BytesIO import ui DEFAULT_ORIENTATION = 0 PORTRAIT = 1 LANDSCAPE = 2 ...

    inside myScript.py ...

    from scene import ui class MyView(ui.View): ...
  • TKInter is a desktop GUI module that accepts mouse input, while the iPhone is a touch based UI. This means there are some interactions and gestures that don't map across between them. For example the phone interface has no analogue of right-click or click-and-drag. Similarly the desktop interaction model has no analogue of a long-press or swipe.

    You can arbitrarily try and assign mappings between some of these, so you could say long press equals right-click, but that might work fine in one application but poorly in another in which long-click might need to be used for another gesture such as to select something for drag-and-drop. No one mapping will work for every application, but at the framework level to make something portable you'd need to have fixed mappings.

    Then you have the issue that the phone doesn't have a concept of floating windows, re-sizable windows, overlapping windows, floating dialogs and menus, scroll bars and many others. How do you do shift-click or control-click on a phone? Conversely on the phone you have conventions like swiping from the edge of the screen and multi-touch gestures. There are very good reasons why even Apple's own OSX GUI framework was not ported directly to iOS.

    It is possible to write UI toolkits from scratch that are designed to map across between touch and desktop paradigms. The way to do this is to identify a subset of gestures and interactions in both models and creating strict mappings between them at the toolkit level. This gives you the portability, but at a cost of sacrificing the ability to use interactions that can't be deterministic-ally mapped to the other platforms. Unfortunately TKInter wasn't designed in terms of sacrificing desktop GUI capabilities in order to make the subset portable to phones, so it has a lot of GUI paradigm interactions and display widgets included that don't port over.

  • For packages hosted on pypy, you can install stash, then use the pip command

    pip install pydicom

    for pure python packages (which do not have C dependencies), this works maybe 75% of the time. in some cases, you may need to use pip download, then manually un tar or unzip the file, and copy the main package folder into site-packages.

    For things on github, you can use git clone, from within stash. Or you can use wget with the github archive url, then un tar or unzip again with stash.

    For individual files, I recommend
    which you set as an application extension script, so you would navigate to the file in safari, then use the share menu to run the savefile script, which will place the file in your Documents folder.

  • @lukaskollmer I got it all working again, except imgurpython.
    I removed it from site-packages and tried to reinstall it with pip, but it wouldn't let me.

  • This sounds like a location problem.

    import will check the site-packages folder in modules & templates\site-packages (there are three folders in Pythonista 3.

    import will also check the current folder and can import something from there.

    import does not import from just anywhere.

  • Thank you so much guys, I've figured it, it really means a lot that you guys took the time to help me.
    I didn't have it in the same folder as my script, ameteur mistake.
    But then again I am an ameteur, so it's to be expected.
    Thanks again, this was A LOT easier to understand, it's great to finally get this sorted.

  • Pythonista 1.6 is only supported on iOS 8 or later. Numpy was added with pythonista 1.5. Pythonista 1.5 is only available to devices running iOS 7 or later. If your device only supports iOS 6, you're out of luck. Check Settings>General>Software Update to see if your device can run iOS 7 or later.

Internal error.

Oops! Looks like something went wrong!