Project

General

Profile

Feature #17973

Separate Python DPMs

Added by Beau Harrison almost 2 years ago. Updated almost 2 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
Python Client Library
Target version:
-
Start date:
10/19/2017
Due date:
% Done:

0%

Estimated time:
Duration:

Description

I understand that there is a use case for Python 2.6 but I would like to suggest that there exist a second Python DPM for Python 3 support.

History

#1 Updated by Richard Neswold almost 2 years ago

  • Category set to Python Client Library

I agree, I'd like to see a Python 3.x interface, too. For this to work, however, we need a different PYTHONPATH for each version. Right now the .pyc files are being stored in the download area: /usr/local/xcons/exe. Maybe create two directories?:

/usr/local/xcons/exe/py2 and
/usr/local/xcons/exe/py3

We could put the appropriate versions in the right location. But then this brings up other questions:

  • I want both targeted Pythons to have roughly the same API, so the DPM module still needs to be called DPM. How can I have two Python modules in the repository targeted for different Pythons? I guess the project could have two subdirectories.
  • Is there a way to get a make file to build the .pyc files for each version of Python?
  • How does PYTHONPATH get set appropriately?

#2 Updated by Richard Neswold almost 2 years ago

I haven't done this (yet!) to the Python acnet repository but, for the Python DPM repository, I created two master branches: master-py2 and master-py3. The master branch has been cleared of source and has a README file describing the organization.

The two master branches can diverge as we tailor each for features available in their respective version of Python. If some code needs to be present in both, we'll use git cherry-pick to transfer the specific changes. These branches should never be merged using git merge as that would try to merge all the historical changes!.

#3 Updated by Richard Neswold almost 2 years ago

Okay. The acnet repo is also set up this way.



Also available in: Atom PDF