Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Overflow error with toga-demo on windows #53

Closed
Badg opened this issue Nov 6, 2015 · 5 comments
Closed

Overflow error with toga-demo on windows #53

Badg opened this issue Nov 6, 2015 · 5 comments

Comments

@Badg
Copy link

Badg commented Nov 6, 2015

Fresh install of toga-demo, with successful install of all dependencies. Running in anaconda on 64-bit windows 7 with 64-bit python. Toga-demo could not execute, threw an OverflowError and then an AttributeError -- see screenshot.

toga-overflow

@freakboy3742
Copy link
Member

Thanks for the report. Toga on Windows is fairly primitive - it hasn't got all the widgets necessary to handle the full toga-demo - so you haven't done anything wrong here. Windows is an area that I accept as important, but it's lower on my personal list of immediate priorities; if anyone is motivated to work on Windows support, especially if they have expertise on native Windows APIs, I'd deeply appreciate the help.

@whmcdonaldiii
Copy link

I'm kind of a noob programmer but I like to tinker around. One of my goals is to help the user experience of Python on Windows. That said, I am a noob (maybe more like a higher level noob). If anyone can point me in a good direction for learning Windows APIs, I'll gladly do the footwork and begin contributing the best I can. Thanks ahead of time.

@freakboy3742
Copy link
Member

@ginoskotheon If you're in a position to help out, that would be amazing!

Unfortunately, I don't know where to point you for learning Windows APIs; I haven't used Windows in any serious capacity for many years now.

I've got two suggestions for getting started - both from a "here's a goal" perspective. If you can get to that goal, I can point

  1. Implement Toga tutorial 0 (and maybe tutorial 1). Do this in several phases:
    a. Implement the app using a completely native Windows API and language.
    b. Extend that app in such a way that it exposes a raw C API.
    c. Implement the app using Python ctypes invoking that C API.
  2. Work out what wrapping is necessary to distribute this windows app as an installable app that behaves the same way that a normal Windows app works.

For point (1), I'm assuming that having a C API invoked over ctypes will be the easiest way to invoke a C# API; however, that may not be the case. Essentially, the task here is to investigate, and see what works and what doesn't. The only goal I have is that the end-user must have a 0 compilation install path. It doesn't matter if the developer needs to compile something, as long as it can be wrapped up as a wheel and distributed as a binary that Just Works(tm).

For (2), see [pybee/Python-macOS-template] for an example for what I mean in a macOS context; I'm looking for the analog of that for windows, which may involve writing an installer script of some kind. I'm assuming WiX or NSIS will be needed here.

@whmcdonaldiii
Copy link

@freakboy3742 Thanks for the response and the guidance. Exactly what I needed. I will begin putting in the time and thought. It will take me a while, probably. But I'm really pumped to help in anyway I can. And if anyone out there is better at this than I am, I would love to collaborate.

@freakboy3742
Copy link
Member

Closing this ticket in favour of general improvement on toga-win32/toga-winrt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants