Installing python3 modules
Running Slackware-14.2/x86_64 here. I'm trying to learn if any installed applications are still dependent on Python2 (version 2.7.17 installed) as its EOL is this coming Thursday and I want to clean out all Python2 modules and replace them with their Python3 versions (3.9 installed here). This raises several questions. First, I had to remove, reinstall, and upgrade pip. The pip web page says it's compatible with python2 and 3 through 3.8. Does this mean it still does not support Python3.9? Second, pip installed itself in /usr/lib64/python2/site-packages/, not the python3.9/site-packages/ directory. There's not a pip3 so how do I get pip and all other python modules in the python3.9/site-packages/ directory? As an occasional coder (for my own business uses) I'm far from an advanced python user. TIA, Rich -- https://mail.python.org/mailman/listinfo/python-list
Re: Installing python3 modules
> On 26 Dec 2020, at 17:13, Rich Shepard wrote: > > Running Slackware-14.2/x86_64 here. I'm trying to learn if any installed > applications are still dependent on Python2 (version 2.7.17 installed) as > its EOL is this coming Thursday and I want to clean out all Python2 modules > and replace them with their Python3 versions (3.9 installed here). This > raises several questions. > > First, I had to remove, reinstall, and upgrade pip. The pip web page says > it's compatible with python2 and 3 through 3.8. Does this mean it still does > not support Python3.9? It works great with 3.9. which web psge did you see the claim on? Barry > > Second, pip installed itself in /usr/lib64/python2/site-packages/, not the > python3.9/site-packages/ directory. There's not a pip3 so how do I get pip > and all other python modules in the python3.9/site-packages/ directory? > > As an occasional coder (for my own business uses) I'm far from an advanced > python user. > > TIA, > > Rich > -- > https://mail.python.org/mailman/listinfo/python-list > -- https://mail.python.org/mailman/listinfo/python-list
Re: Installing python3 modules
On 12/26/20 10:13 AM, Rich Shepard wrote: Running Slackware-14.2/x86_64 here. I'm trying to learn if any installed applications are still dependent on Python2 (version 2.7.17 installed) as its EOL is this coming Thursday and I want to clean out all Python2 modules and replace them with their Python3 versions (3.9 installed here). This raises several questions. First, I had to remove, reinstall, and upgrade pip. The pip web page says it's compatible with python2 and 3 through 3.8. Does this mean it still does not support Python3.9? pip supports 3.9 fine, and is just about to lose support for 2.x entirely. Second, pip installed itself in /usr/lib64/python2/site-packages/, not the python3.9/site-packages/ directory. There's not a pip3 so how do I get pip and all other python modules in the python3.9/site-packages/ directory? this sounds like a Slack packaging issue, have you checked with appropriate forums_ -- https://mail.python.org/mailman/listinfo/python-list
Re: Installing python3 modules
On Sat, 26 Dec 2020, Mats Wichmann wrote: pip supports 3.9 fine, and is just about to lose support for 2.x entirely. Mats, Yes, it does. this sounds like a Slack packaging issue, have you checked with appropriate forums_ It's apparently a local issue: my python3 packages ended up in /usr/lib/python2.7/site-packages/ rather than //usr/lib64/python3.9/site-packages/. I'm rebuilding all installed python3 packages. Stay well, Rich -- https://mail.python.org/mailman/listinfo/python-list
Pyrebase auth
I am using signup method:
user_signup = auth.create_user_with_email_and_password(email, password)
and my firebase rules are:
{
"rules": {
".read": false,
".write": false,
"$localId": {
".write": "auth.uid === $localId",
".read": "auth.uid === $localId"
}
}
}
I used:
data = {"item1":"hat","item2":"car"}
results = db.child("users").update(data, user['idToken'])
the only way to patch (update) is to use:
".read": true,
".write": true,
which means that anyone can read or write in my database where I only want the
user to write or read if his idtoken or localid is authorized, even if data is
outside his region for ex:
database:
"number_of_users":"2"
"userlocalid":
{"item1":"hat"}
{"item2":"car"}
--
https://mail.python.org/mailman/listinfo/python-list
Re: Installing python3 modules
On 12/26/2020 12:13 PM, Rich Shepard wrote: Running Slackware-14.2/x86_64 here. I'm trying to learn if any installed applications are still dependent on Python2 (version 2.7.17 installed) as its EOL is this coming Thursday and I want to clean out all Python2 modules and replace them with their Python3 versions (3.9 installed here). This raises several questions. First, I had to remove, reinstall, and upgrade pip. The pip web page says it's compatible with python2 and 3 through 3.8. Does this mean it still does not support Python3.9? Second, pip installed itself in /usr/lib64/python2/site-packages/, not the python3.9/site-packages/ directory. Pip is a python code run by a python interpreter. It installs itself in the site-packages of the python you use to run it. 'pythonx -m ensurepip' will make sure some pip is available for pythonx. 'pythonx -m pip' will then run the pythonx pip and manipulate the contents of its site-packages. There's not a pip3 Separate 'pip' executables can be ambiguous as to which python they will invoke. Some people consider them a mistake. so how do I get pip and all other python modules in the python3.9/site-packages/ directory? See above. Run pip with python3.9, however that is spelled on a particular system. I don't know if all the modules you want have versions compatible with 3.9, but anything actively maintained should. The 3.8 versions of pure python modules will often run with 3.9 without change, even if not yet certified to do so by the authors. -- Terry Jan Reedy -- https://mail.python.org/mailman/listinfo/python-list
Re: Installing python3 modules
On Sat, 26 Dec 2020, Barry Scott wrote: It works great with 3.9. which web psge did you see the claim on? Barry, I don't recall which pip3 installation page it was. But I used 'python3 get-pip.py' and that worked. Stay well, Rich -- https://mail.python.org/mailman/listinfo/python-list
Re: Installing python3 modules
On Sat, 26 Dec 2020, Terry Reedy wrote: Separate 'pip' executables can be ambiguous as to which python they will invoke. Some people consider them a mistake. Terry, Until there's no more python2 it can remain confusing. I found part, if not all, of my problem. The SlackBuild scripts for multi-version python modules (such as Pygment) have install instructions for both python2 and python3, in that order. Since there's a python2 version installed the script installs Pygment (and others) there and not also in the python3 site-packages/ directory. so how do I get pip and all other python modules in the python3.9/site-packages/ directory? Fixed. Thanks, Rich -- https://mail.python.org/mailman/listinfo/python-list
Debian testing and virtual environment error message
Simlar to Rich's asking about how to deal with python3.9 I'm not able to to get my virtual environment set up to work now and I'm not sure how to go about fixing this. As it is testing I may have broken it somehow but I do not know how to fix this. I asked on the Debian user mailing list and nobody had any response/ideas. Note, this isn't a production system and I don't mind it being temporarily broken, but I also would like to know what is going on and how to fix this sort of thing. I do have python-is-python3 package installed and there are no python2 programs anywhere on this system that I know of. When i run the command: = $ cd /home/me/src/salsa $ python -m venv env setting up virtual environment /home/me/src/salsa/env The virtual environment was not created successfully because ensurepip is not available. On Debian/Ubuntu systems, you need to install the python3-venv package using the following command. apt-get install python3-venv You may need to use sudo with that command. After installing the python3-venv package, recreate your virtual environment. Failing command: ['/home/me/src/salsa/env/bin/python', '-Im', 'ensurepip', '--upgrade', '--default-pip'] = The package mentioned is installed: = $ dpkg -l | grep python3-venv ii python3-venv 3.9.0-4amd64 pyvenv-3 binary for python3 (default python3 version) = Also the following looks interesting but I'm not sure why there is no 3.9 version available: = $ dpkg -l | grep python-is ii python-is-python33.8.6-3all symlinks /usr/bin/python to python3 # su - entered password # apt-get install python-is-python3 -t unstable Reading package lists... Done Building dependency tree Reading state information... Done python-is-python3 is already the newest version (3.8.6-3). 0 upgraded, 0 newly installed, 0 to remove and 250 not upgraded. = any ideas? :) thanks! songbird -- https://mail.python.org/mailman/listinfo/python-list
Re: Debian testing and virtual environment error message
On Sun, Dec 27, 2020 at 11:31 AM songbird wrote: > > > Simlar to Rich's asking about how to deal with python3.9 > I'm not able to to get my virtual environment set up to work > now and I'm not sure how to go about fixing this. > > As it is testing I may have broken it somehow but I do not > know how to fix this. > > I asked on the Debian user mailing list and nobody had any > response/ideas. > > Note, this isn't a production system and I don't mind it > being temporarily broken, but I also would like to know what > is going on and how to fix this sort of thing. > > I do have python-is-python3 package installed and there are > no python2 programs anywhere on this system that I know of. > What does this say? $ which python ChrisA -- https://mail.python.org/mailman/listinfo/python-list
Re: Debian testing and virtual environment error message
Chris Angelico wrote: ... > $ which python /usr/bin/python for both user and root looking at /usr/bin it looks like: lrwxrwxrwx 1 root root 7 Nov 3 03:20 python -> python3 lrwxrwxrwx 1 root root 9 Dec 6 05:36 python3 -> python3.9 -rwxr-xr-x 1 root root 5479736 Dec 8 02:51 python3.9 thanks, songbird -- https://mail.python.org/mailman/listinfo/python-list
Re: Debian testing and virtual environment error message
songbird wrote: ... > The package mentioned is installed: > > >= > > $ dpkg -l | grep python3-venv > ii python3-venv 3.9.0-4amd64 >pyvenv-3 binary for python3 (default python3 version) > here is something i missed including in my first post, but i don't know if this matters: ii python3.9-venv 3.9.1-1amd64 Interactive high-level object-oriented language (pyvenv binary, version 3.9) songbird -- https://mail.python.org/mailman/listinfo/python-list
