MacOSX 11.7.9 no idea what's wrong
MW0SBX opened this issue · 19 comments
marc@marcs-MacBook-Pro ~ % python3 -m pygpsclient
/Users/marc/Library/Python/3.8/lib/python/site-packages/urllib3/init.py:34: NotOpenSSLWarning: urllib3 v2.0 only supports OpenSSL 1.1.1+, currently the 'ssl' module is compiled with 'LibreSSL 2.8.3'. See: urllib3/urllib3#3020
warnings.warn(
macOS 11 (1107) or later required, have instead 11 (1106) !
zsh: abort python3 -m pygpsclient
marc@marcs-MacBook-Pro ~ %
I just noticed that bit macOS 11 (1107) or later required, have instead 11 (1106) ! but Mac OSX won't upgrade passed 11.7.9 on my machine. Any way to override it. ???
Hi @MW0SBX
Sorry you're having difficulties, but - failing Google - I'm afraid you may need to direct this question to the maintainer of the urllib3 library, which is the one that seems to be giving you grief. PyGPSClient itself has no pinned OpenSSL version dependency.
If you Google the error, there appear to be quite a few suggested resolutions e.g. https://stackoverflow.com/questions/76187256/importerror-urllib3-v2-0-only-supports-openssl-1-1-1-currently-the-ssl-modu. The options appear to come down to:
- Install in a dedicated virtual environment (
virtualenv
) - see README for instructions. - Install an older version of urllib3
- Install a newer version of OpenSSL
Note, however, that:
- You may need to use homebrew or macports to install older libraries if pip can't resolve them from standard MacOS repos.
- Running older versions of cryptographic libraries like OpenSSL may leave your machine vulnerable to cyber attacks, though I'm guessing your Mac is > ≈8 years old if it won't upgrade beyond 11.7.9 (Big Sur), so that ship may have sailed?
Did you explicitly install LibreSSL yourself, or was it installed as part of another app? You could try uninstalling LibreSSL, retry installing urllib3 and seeing if pip can then resolve the correct OpenSSL dependency automatically.
Unfortunately I no longer have a machine that old to play with (mainly for professional security compliance reasons).
Maybe you need to stop using urllib3 because it stops this project working on any Mac I used opencore patcher and upgraded to osx 12.6.8 and it still complains about urllib3 and still doesn't work.
Maybe you need to stop using urllib3 because it stops this project working on any Mac I used opencore patcher and upgraded to osx 12.6.8 and it still complains about urllib3 and still doesn't work.
I can assure you that PyGPSClient works fine on MacOS 12 or 13 using the official Python.org version of Python (I'm using it on MacOS 13.5.1 as we speak - it's my standard development environment), and many others have installed it without difficulty on older MacOS 11 machines. I believe the problem is not with PyGPSClient or urllib3 - it's with the specific version of OpenSSL you have installed on your machine, as the error message tells you.
PyGPSClient doesn't actually use urllib3
explicitly - it uses the standard requests
library to retrieve any internet resources it needs, but this in turn has a lower-level dependency on urllib3
which I have absolutely no control over. I'm not about to write a generic Python internet protocol handler from scratch.
Have you tried installing PyGPSClient using virtualenv? This should in theory provide an 'insulated environment' into which pip can install all the relevant library dependencies without coming into conflict with external apps.
i tried sudo apt install tk-dev it then complains about java i went and got java and it still complains that its not installed. Sent from Outlook for Androidhttps://aka.ms/AAb9ysg
…
________________________________ From: Marc ... @.> Sent: Tuesday, August 29, 2023 9:43:42 PM To: semuconsulting/PyGPSClient @.>; semuconsulting/PyGPSClient @.> Cc: Mention @.> Subject: Re: [semuconsulting/PyGPSClient] MacOSX 11.7.9 no idea what's wrong (Issue #88) At the moment it complaining about Tkinter Sent from Outlook for Androidhttps://aka.ms/AAb9ysg
________________________________ From: SEMU Admin @.> Sent: Tuesday, August 29, 2023 9:24:20 PM To: semuconsulting/PyGPSClient @.> Cc: Marc @.>; Mention @.> Subject: Re: [semuconsulting/PyGPSClient] MacOSX 11.7.9 no idea what's wrong (Issue #88) Maybe you need to stop using urllib3 because it stops this project working on any Mac I used opencore patcher and upgraded to osx 12.6.8 and it still complains about urllib3 and still doesn't work. I can assure you that PyGPSClient works fine on MacOS 12 or 13 using the official Python.orghttps://www.python.org/ version of Python (I'm using it on MacOS 13.5.1 as we speak - it's my standard development environment), and many others have installed it without difficulty on older MacOS 11 machines. I believe the problem is not with PyGPSClient or urllib3 - it's with the specific version of OpenSSL you have installed on your machine, as the error message tells you. PyGPSClient doesn't actually use urllib3 explicitly - it uses the standard requests library to retrieve any internet resources it needs, but this in turn has a lower-level dependency on urllib3 which I have absolutely no control over. I'm not about to write a generic Python internet protocol handler from scratch. Have you tried installing PyGPSClient using virtualenv? This should in theory provide an 'insulated environment' into which pip can install all the relevant library dependencies without coming into conflict with external apps. — Reply to this email directly, view it on GitHub<#88 (comment)>, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AAZ5ZIXOHXW4DA4FELL7FMDXXZFXJANCNFSM6AAAAAA4DG4LSM. You are receiving this because you were mentioned.Message ID: @.***>
![Screenshot 2023-08-29 at 21 50 01](https://private-user-images.githubusercontent.com/28569967/264157520-58baf938-8328-493a-978a-fd8054940d4e.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTUwOTY4NjQsIm5iZiI6MTcxNTA5NjU2NCwicGF0aCI6Ii8yODU2OTk2Ny8yNjQxNTc1MjAtNThiYWY5MzgtODMyOC00OTNhLTk3OGEtZmQ4MDU0OTQwZDRlLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA1MDclMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNTA3VDE1NDI0NFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTI0ZGY2ZDJlNDYwOTllM2ZmNDFlYjlhOWY4ZjY4YTI2MDNmNjVmYWIyMzlhNDhiMTY0MTBlYmRlYTM3ZWJkOTYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.y4NnQyYwzcdJV6vOe0udJ3EcrmFqZdLgfpjVZGZVpFE)
As explained in the README.md, the version of Python that is installed by default on even the latest MacBooks contains a long-deprecated version of tkinter - 8.5). To get round this, you simply need to install the latest official version of Python from Python.org. This will install tkinter 8.6 along with all the other necessary dependencies. You don't need to install tk-dev
or java
or anything else like that.
I've literally just done this on my old 2015 MacBook Air - it took less than 2 minutes and, as you can see above, it works fine.
I am genuinely sorry you're having a hard time installing on your machine, but short of reinstalling MacOS from scratch (from the official Apple source - not an opencore patch) and then installing a fresh copy of Python 3.11 from Python.org, I'm not sure what more I can suggest.
As I say, PyGPSClient has been installed on thousands of MacOS machines - both new and old - without difficulty provided the user has an official version of Python >=3.8 with tkinter >=8.6 installed. I've no idea why Apple still bundles tkinter 8.5 - it's been deprecated for well over 10 years - but I have no control over that.
Would you be able to send me the complete log and traceback from the latest attempted PyGPSClient installation - the one that is now complaining about Tk? i.e. run this command and send me the complete log.txt
file:
python3 -m pip install PyGPSClient > log.txt
Can you confirm what you get in response to the following commands (I've illustrated the responses I'm getting on my machine by way of comparison):
from the terminal:
which python3
python3 -V
/Library/Frameworks/Python.framework/Versions/3.11/bin/Python3
Python 3.11.4
from an interactive Python3 prompt:
import tkinter
print(tkinter.TclVersion)
tcl = tkinter.Tcl()
print(tcl.call("info", "patchlevel"))
8.6
'8.6.12'
I'm only seeing a partial installation log there (which looks fine) - do you have the complete log?
if you run the command exactly as follows...
python3 -m pip install PyGPSClient > log.txt
... you should end up with a file named log.txt
in the same directory. Just send me the complete file - if it's too big to upload to GitHub, send it as an email attachment to semuadmin@semuconsulting.com.
Hi @MW0SBX
Are you able to provide the installation log requested?
Happy to continue to investigate, but I'll close the issue in 5 days if no further response.
I got it working using i think a cleanup using Brew a few days ago.
Ah OK great. I'll close this now.