[tlu] Monterey and TLU

Adam R. Maxwell amaxwell at mac.com
Tue Oct 26 18:25:55 CEST 2021

Thanks, guys. It's helpful to see the content of that alert, which is unhelpful and <opprobrious epithet deleted>. Apple's plan is to entirely remove Python as a giant FU to developers who accepted it as part of the system (I recall a time when Apple was pushing Python and Ruby as first-class application languages, with Xcode templates to develop applications). https://mjtsai.com/blog/2019/06/04/scripting-languages-to-be-removed/Anyway, I guess over the next year I'll have to rewrite all of my Python scripts in Objective-C and/or shell script, because the world's richest company can't be arsed to keep shipping scripting language support with the remains of its once-fine UNIX operating system. They're proud of the douchey alerts, too:https://twitter.com/mikeymikey/status/1401981286680461314TeX Live will have to start installing its own Perl, as well.On Oct 26, 2021, at 9:05 AM, Bruno Voisin via tlu <tlu at tug.org> wrote:On 25 Oct 2021, at 21:18, Bruno Voisin <bvoisin at icloud.com> wrote:In that case, then the warning when opening TLU is to tell that TLU uses Python 2 and Apple plans to remove Python 2 in a future release (to replace it with Python 3, or remove Python altogether, is unclear).The fact is, for the moment it seems Python 2.7 is still provided (in /System/Library/Frameworks/Python.framework/Versions/2.7). So the warning can be safely ignored, I think.Summarizing some off-list discussion with Herb:- The warning is<TLU Warning.png>and is indeed about Python. When you click on the "Learn More..." button, you are brought to the pagehttps://www.python.org/doc/sunset-python-2/about the obsolescence of Python 2.- Adam has made sure (since version 1.13 I think, according to the Release Notes) that TLU runs fine with both Python 2 and 3. It seems to be (a catch by Herb) the shebang line#!/usr/bin/python for example in /Applications/TeX/TeX Live Utility.app/Contents/Resources/update_check.py, or maybe#!/usr/bin/env pythonin /Applications/TeX/TeX Live Utility.app/Contents/MacOS/parse_tlpdb.py, that calls the built-in macOS Python, currently Python 2.7. This triggers the above warning.- Indeed, the built-in Python is 2.7. It lives in/System/Library/Frameworks/Python.frameworkIn Terminal (removing blank lines):% python WARNING: Python 2.7 is not recommended.  This version is included in macOS for compatibility with legacy software.  Future versions of macOS will not include Python 2.7.  Instead, it is recommended that you transition to using 'python3' from within Terminal. Python 2.7.18 (default, Oct  2 2021, 04:20:38)  [GCC Apple LLVM 13.0.0 (clang-1300.0.29.1) [+internal-os, ptrauth-isa=deploymen on darwin- Python 3 is not built-in and comes with the Developer Tools. There are two ways to install the Apple version. If you run python3 in Terminal you get% python3                  xcode-select: note: no developer tools were found at '/Applications/Xcode.app', requesting install. Choose an option in the dialog to download the command line developer tools.and at the same an application Install Command Line Developer Tools launches itself offering to install the command line developer tools, which include python3:<Python 3 Installation.png>No authentication is required, only a Command Line Tools Licence Agreement. Afterwards% python3 Python 3.8.9 (default, Aug  3 2021, 19:21:54)  [Clang 13.0.0 (clang-1300.0.29.3)] on darwinand Python 3 lives in/Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework- Alternatively, you may install Xcode from the App Store. In that event, Python 3 will live in/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework- It's unclear what will happen when Apple removes Python 2.7. One possibility is that /usr/bin/python will remain and be altered to point to python3, which either will have replaced Python 2.7 in the OS, or will need to be installed separately as above.Another possibility is that the python command goes away and only python3 will be recognized by the OS, which (I imagine) would mean the .py scripts would need to test for the available python if any and use explicitly either python or python3 depending on the result.Maybe this doesn't make sense, I've never really used Python myself.Bruno
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://tug.org/pipermail/tlu/attachments/20211026/354bb7dc/attachment.html>

More information about the tlu mailing list.