[Pythonmac-SIG] Building plans .....

Jack Jansen jack.jansen at cwi.nl
Sat Mar 14 17:22:18 EDT 2020


I’m having an incredible amount of deja-vu in this conversation. We seem to be heading down the path of talking about little-documented APIs and such the same way we were doing 15 or 18 years ago….

Christopher,
can you explain what the problem is that you’re running into? Why is there a problem with the Mac Python builds having a different structure than other Unix Python builds? Windows Python builds also have a different structure, does the problem occur there as well?

From your original post it seems that the problems are with the Anaconda/Conda-forge distribution treating MacOS as “just another unix distribution”, with the idea that “Mac GUI compatibility” wouldn’t be too important for the Anaconda users, or could be handled with the pythonw workaround shellscript.

But actually “MacOS-compatible” would be a more accurate term here, because I’m pretty sure there are a whole lot of APIs that have nothing to do with the GUI but won’t work unless you’re running from a bundle: definitely Open Scripting, but probably also audio/video capture, probably anything using keychain like crypto serveices, maybe bluetooth, maybe USB, probably anything using the GPU for computations….. 

So basically if you build Python for MacOS as if it is “just another BSD distribution” then that is indeed what you get: a Python for just another BSD distribution.

Hmm, that was a long sentence for what was intended to be the question: “What is the problem with using a normal MacOS Framework build of Python for Anaconda”?

Jack

> On  14-Mar-2020, at 14:54 , Ronald Oussoren <ronaldoussoren at mac.com> wrote:
> 
> 
> 
>> On 13 Mar 2020, at 20:36, Christopher Barker <pythonchb at gmail.com <mailto:pythonchb at gmail.com>> wrote:
>> 
>> There is a private API that makes it possible to use GUI libraries outside of an app bundle and that’s used by a number of projects, but I wouldn’t want to use that in Python.
>> 
>> Is that what TK is doing? 
> 
> I don’t know.
>> 
>> And while probably not good to build it into Python itself, what about building into the GUI toolkits? 
>> 
>> Do you have a reference to that API?
> 
> I don’t have a reference handy, it has come up before either on this list or the python tracker (years back). IIRC someone found the API by checking how the bundled java VM managed to use GUI APIs without being in an app bundle.
> 
> Apple is clearly preferring application code packaged as app bundles, and effectively doesn’t care about traditional Unix-y use of macOS. The need for an app bundle when using frameworks is just one example of that. Another example are the issues that keep popping up when trying to use Apple frameworks in child processes after calling os.fork(). 
> 
> Because of this I don’t think it is worthwhile to try to work around this limitation by calling private APIs. That’s even before considering use cases that involve distributing code through the macOS app store.
> 
> Ronald
>> 
> Twitter: @ronaldoussoren
> Blog: https://blog.ronaldoussoren.net/ <https://blog.ronaldoussoren.net/>

--
Jack Jansen, <Jack.Jansen at cwi.nl>, http://www.cwi.nl/~jack
If I can't dance I don't want to be part of your revolution -- Emma Goldman



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/pythonmac-sig/attachments/20200314/cf10afba/attachment.html>


More information about the Pythonmac-SIG mailing list