You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ranger.apache.org by "Krzysztof Sobolewski (Jira)" <ji...@apache.org> on 2025/02/07 11:16:00 UTC
[jira] [Created] (RANGER-5133) Clarify requirements regarding Python version
Krzysztof Sobolewski created RANGER-5133:
--------------------------------------------
Summary: Clarify requirements regarding Python version
Key: RANGER-5133
URL: https://issues.apache.org/jira/browse/RANGER-5133
Project: Ranger
Issue Type: Task
Components: admin, tagsync, usersync
Affects Versions: 2.5.0
Reporter: Krzysztof Sobolewski
There are plenty of Python scripts in Ranger, but it's unclear to me what version of Python they should be running on. Our deployment environment contains a fairly recent version of Python 3 (because Python 2 is long EOL), and, for example, the database scripts do not work. For example, we had to make the following change:
{code:java}
fcp = ConfigParser()
fcp.optionxform = str
- fcp.readfp(config)
+ fcp.read_file(config)
{code}
That's because `readfp` is no longer available in newer Python versions. Or, the escape syntax in strings has changed and newer Python spews a lot of warnings about it (the old syntax is about to be removed in the future).
So my request here is to clarify that and/or fixup the scripts so they work on current version of Python. Thanks!
--
This message was sent by Atlassian Jira
(v8.20.10#820010)