rlm_python / v4.x vs. rlm_python3 / v3.x
Hi, I'd like to ask for clarification on Python 3 support status, from the python code point of view. From what I see here, and in the ticket (https://github.com/FreeRADIUS/freeradius-server/issues/2351), rlm_python3 appears to work alright for those who have tested it. On the other hand, https://freeradius.org/modules/?mod=rlm_python3 lists rlm_python3 as deprecated, although @alandekok does suggest using it on Freeradius 3.x on this mailing list this month. If one were to write python code, in Python 3, right now, should one target the stable Freeradius 3.x branch on rlm_python3, or Freeradius master/4.x branch with rlm_python compiled against Python 3? The API towards Python code probably doesn't change much between the two? - Hessu
On 4/28/20 05:38, Heikki Hannikainen wrote:
Hi,
(SNIP)>
The API towards Python code probably doesn't change much between the two?
- Hessu
If I *recall* (anyone who knows better, do please feel free to correct me), I BELIEVE[0] that the 3.x rlm_python3 will take the place of rlm_python in 4.x (since python 2.x is now officially EOL'd), and that rlm_python3 for 3.x is a backport of rlm_python on 4.x. I believe you should not need to make any changes to your rlm_python3 module for 4.x rlm_python. [0] I admittedly read it late at night so the details may be hazy, and it may be outdated, but this supposition comes from the information in this GH issue: https://github.com/FreeRADIUS/freeradius-server/issues/2351 -- brent saner https://square-r00t.net/ GPG info: https://square-r00t.net/gpg-info
On Apr 28, 2020, at 5:38 AM, Heikki Hannikainen <hessu@hes.iki.fi> wrote:
I'd like to ask for clarification on Python 3 support status, from the python code point of view. From what I see here, and in the ticket (https://github.com/FreeRADIUS/freeradius-server/issues/2351), rlm_python3 appears to work alright for those who have tested it.
Yes. That module was just added last year.
On the other hand, https://freeradius.org/modules/?mod=rlm_python3 lists rlm_python3 as deprecated, although @alandekok does suggest using it on Freeradius 3.x on this mailing list this month.
It's listed that way because rlm_python3 is not in v4. Instead, we just use rlm_python there.
If one were to write python code, in Python 3, right now, should one target the stable Freeradius 3.x branch on rlm_python3, or Freeradius master/4.x branch with rlm_python compiled against Python 3?
Don't use the master branch. It's still in major development. Use v3, and rlm_python3. It's fine. Alan DeKok.
On Tue, 28 Apr 2020, Alan DeKok wrote:
On Apr 28, 2020, at 5:38 AM, Heikki Hannikainen <hessu@hes.iki.fi> wrote:
I'd like to ask for clarification on Python 3 support status, from the python code point of view. From what I see here, and in the ticket (https://github.com/FreeRADIUS/freeradius-server/issues/2351), rlm_python3 appears to work alright for those who have tested it.
Yes. That module was just added last year.
On the other hand, https://freeradius.org/modules/?mod=rlm_python3 lists rlm_python3 as deprecated, although @alandekok does suggest using it on Freeradius 3.x on this mailing list this month.
It's listed that way because rlm_python3 is not in v4. Instead, we just use rlm_python there.
If one were to write python code, in Python 3, right now, should one target the stable Freeradius 3.x branch on rlm_python3, or Freeradius master/4.x branch with rlm_python compiled against Python 3?
Don't use the master branch. It's still in major development.
Use v3, and rlm_python3. It's fine.
Excellent, thank you for the replies. Additionally Matthew Newton simply replied (off-list) "Use rlm_python3 in v3." so I'm guess the direction is clear. Thanks again! - Hessu
On 28/04/2020 12:41, Heikki Hannikainen wrote:
Use v3, and rlm_python3. It's fine.
Excellent, thank you for the replies. Additionally Matthew Newton simply replied (off-list) "Use rlm_python3 in v3." so I'm guess the direction is clear.
Hit the wrong button, that was meant to go to the list. -- Matthew
Will the official Debian/Ubuntu packages on https://networkradius.com/freeradius-packages/ and the build process for Debian/Ubuntu packages from source include rlm_python3 in 3.x by default if the necessary python 3 dev packages are available on the system? Kind regards, Christian Strauf -- Dipl.-Math. Christian Strauf Head of Network Services Department Clausthal Univ. of Technology E-Mail: strauf@rz.tu-clausthal.de Rechenzentrum Web: www.rz.tu-clausthal.de Erzstraße 18 Tel.: +49-5323-72-2086 Fax: -992086 D-38678 Clausthal-Zellerfeld
On 28/04/2020 12:48, Christian Strauf wrote:
Will the official Debian/Ubuntu packages on
https://networkradius.com/freeradius-packages/
and the build process for Debian/Ubuntu packages from source include rlm_python3 in 3.x by default if the necessary python 3 dev packages are available on the system?
Packages built from source will include it if the build dependencies are on the system. The official packages don't include it yet. -- Matthew
Will the official Debian/Ubuntu packages on https://networkradius.com/freeradius-packages/ and the build process for Debian/Ubuntu packages from source include rlm_python3 in 3.x by default if the necessary python 3 dev packages are available on the system? Packages built from source will include it if the build dependencies are on the system. I don't think so. At least not when building 3.0.21 Ubuntu packages using the source on github because rlm_python3 is not listed as stable in
src/modules/stable if I'm not mistaken. Christian
On 28/04/2020 13:01, Christian Strauf wrote:
Packages built from source will include it if the build dependencies are on the system. I don't think so. At least not when building 3.0.21 Ubuntu packages using the source on github because rlm_python3 is not listed as stable in
src/modules/stable
Hmm, I thought that had been added. It's easy enough to add it to the list before building though. -- Matthew
Hmm, I thought that had been added.
It's easy enough to add it to the list before building though. Yes, that's true, however, it wasn't entirely clear from the github repo whether or not the rlm_python3 module was considered stable for 3.x and the fact that it wasn't listed in src/modules/stable led us to believe that it wasn't stable yet.
We'll add rlm_python3 there and test it. Thanks for confirming that it's considered stable. Christian
participants (5)
-
Alan DeKok -
brent s. -
Christian Strauf -
Heikki Hannikainen -
Matthew Newton